Closed Bug 943391 Opened 11 years ago Closed 11 years ago

nsPipe3.cpp(302) : warning C4355: 'this' : used in base member initializer list

Categories

(Core :: XPCOM, defect)

x86
Windows XP
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla28

People

(Reporter: dholbert, Assigned: dholbert)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

Build warnings: { c:\builds\moz2_slave\try-w32-0000000000000000000000\build\xpcom\io\nsPipe3.cpp(302) : warning C4355: 'this' : used in base member initializer list c:\builds\moz2_slave\try-w32-0000000000000000000000\build\xpcom\io\nsPipe3.cpp(303) : warning C4355: 'this' : used in base member initializer list } https://tbpl.mozilla.org/php/getParsedLog.php?id=31083482&tree=Try
Attached patch fix v1Splinter Review
Attachment #8338526 - Flags: review?(nfroyd)
RE whether this is safe: mInput is of type nsPipeInputStream, and its constructor simply saves a pointer to the pipe -- it doesn't dereference it. http://mxr.mozilla.org/mozilla-central/source/xpcom/io/nsPipe3.cpp#108 mOutput is of type nsPipeOutputStream, and the same is true of it. (no dereferencing in the constructor) http://mxr.mozilla.org/mozilla-central/source/xpcom/io/nsPipe3.cpp#165 So, the "this" usage is safe, and MOZ_THIS_IN_INITIALIZER_LIST is appropriate.
Attachment #8338526 - Flags: review?(nfroyd) → review+
Status: NEW → ASSIGNED
Flags: in-testsuite-
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla28
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: