Closed
Bug 617971
Opened 14 years ago
Closed 14 years ago
nsStyleAnimation::ExtractComputedValue leaks pair when StyleCoordToCSSValue fails
Categories
(Core :: CSS Parsing and Computation, defect)
Core
CSS Parsing and Computation
Tracking
()
RESOLVED
FIXED
mozilla2.0b8
Tracking | Status | |
---|---|---|
blocking2.0 | --- | final+ |
People
(Reporter: timeless, Assigned: timeless)
References
(Blocks 1 open bug)
Details
(Keywords: coverity, memory-leak)
Attachments
(1 file, 2 obsolete files)
2.79 KB,
patch
|
timeless
:
review+
bzbarsky
:
approval2.0+
|
Details | Diff | Splinter Review |
2146 nsStyleAnimation::ExtractComputedValue(nsCSSProperty aProperty, 2159 switch (animType) { 2160 case eStyleAnimType_Custom: 2161 switch (aProperty) { 2256 case eCSSProperty__moz_transform_origin: { 2259 nsCSSValuePair *pair = new nsCSSValuePair; 2260 if (!pair || 2261 !StyleCoordToCSSValue(styleDisplay->mTransformOrigin[0], 2262 pair->mXValue) || 2263 !StyleCoordToCSSValue(styleDisplay->mTransformOrigin[1], 2264 pair->mYValue)) { 2265 return PR_FALSE; 2266 } 2574 nsCSSValuePair *pair = new nsCSSValuePair; 2575 if (!pair || 2576 !StyleCoordToCSSValue(horiz, pair->mXValue) || 2577 !StyleCoordToCSSValue(vert, pair->mYValue)) { 2578 return PR_FALSE;
Updated•14 years ago
|
blocking2.0: --- → ?
Comment 2•14 years ago
|
||
Comment on attachment 496602 [details] [diff] [review] patch r=me
Attachment #496602 -
Flags: review?(bzbarsky)
Attachment #496602 -
Flags: review+
Attachment #496602 -
Flags: approval2.0+
Comment 3•14 years ago
|
||
I think elsewhere in the same file we use nsAutoPtr<> to handle this deletion -- should we do that here as well, for consistency & future-proofing against other newly-added early-return cases?
Comment 4•14 years ago
|
||
That'd be fine too.
Comment 5•14 years ago
|
||
Attachment #496602 -
Attachment is obsolete: true
Attachment #496622 -
Flags: review+
Keywords: checkin-needed
Updated•14 years ago
|
Attachment #496621 -
Flags: review?(bzbarsky)
Comment on attachment 496621 [details] [diff] [review] Remove StyleCoordToCSSValue's useless return value please use another bug for other stuff.
Attachment #496621 -
Attachment is obsolete: true
Attachment #496621 -
Flags: review?(bzbarsky)
Updated•14 years ago
|
Attachment #496622 -
Flags: approval2.0+
Comment 8•14 years ago
|
||
Landed: http://hg.mozilla.org/mozilla-central/rev/5677a819829a
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → mozilla2.0b8
blocking2.0: ? → final+
Updated•6 years ago
|
Blocks: coverity-analysis
You need to log in
before you can comment on or make changes to this bug.
Description
•