Closed
Bug 451079
Opened 16 years ago
Closed 16 years ago
Make setting NULL to an outparam on failure ok
Categories
(Developer Infrastructure :: Source Code Analysis, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: benjamin, Assigned: dmandelin)
Details
Attachments
(4 files, 1 obsolete file)
1.10 KB,
patch
|
dmandelin
:
review+
|
Details | Diff | Splinter Review |
858 bytes,
patch
|
Details | Diff | Splinter Review | |
1.85 KB,
patch
|
Details | Diff | Splinter Review | |
1.16 KB,
application/octet-stream
|
Details |
It turns out that we have lots of code that assumes setting an outparam to NULL on failure is ok. So, rather than try to rewrite the world, I'd like to suppress this class of warning... I have a trivial patch to do that, but it turns out there are some edge cases that need tightening up... I'll attach a testcase shortly.
Reporter | ||
Comment 1•16 years ago
|
||
Attachment #334320 -
Flags: review?(dmandelin)
Assignee | ||
Updated•16 years ago
|
Attachment #334320 -
Flags: review?(dmandelin) → review+
Reporter | ||
Comment 2•16 years ago
|
||
This testcase is the fairly common null pattern that needs tweaking. Basically, if you explicitly test the value of the outparam, the state machine should treat is as a NULL-set variable.
Reporter | ||
Comment 3•16 years ago
|
||
Pushed the first part: http://hg.mozilla.org/mozilla-central/index.cgi/rev/1962de2d4e92
Assignee | ||
Comment 4•16 years ago
|
||
This should take care of it. By the way, e3.cpp should now succeed. Should we just rename it to onull2.cpp and move it to that test category.
Reporter | ||
Comment 5•16 years ago
|
||
Comment on attachment 334353 [details] [diff] [review] Patch for onull.cpp test case Looks good. Yes, go ahead and do the file-move, and I think there's an extraneous FLOW_PASS_TESTCASES in the patch.
Attachment #334353 -
Flags: review+
Assignee | ||
Comment 6•16 years ago
|
||
Assignee | ||
Updated•16 years ago
|
Keywords: checkin-needed
Assignee | ||
Updated•16 years ago
|
Attachment #334353 -
Attachment is obsolete: true
Assignee | ||
Comment 7•16 years ago
|
||
Reporter | ||
Comment 8•16 years ago
|
||
pushed to mozilla-central: http://hg.mozilla.org/mozilla-central/index.cgi/rev/3390347493fd
Reporter | ||
Comment 9•16 years ago
|
||
You forgot to add/rename the testcases in the previous commit. I've fixed this on mozilla-central with the following commit: http://hg.mozilla.org/mozilla-central/rev/a4d2e6549f7f
Updated•16 years ago
|
Version: unspecified → Trunk
Updated•6 years ago
|
Product: Core → Firefox Build System
Updated•2 years ago
|
Product: Firefox Build System → Developer Infrastructure
You need to log in
before you can comment on or make changes to this bug.
Description
•