Closed Bug 982373 Opened 6 years ago Closed 6 years ago

Leak of nsROCSSPrimitiveValue on early return from nsComputedDOMStyle::DoGetTextDecoration

Categories

(Core :: CSS Parsing and Computation, defect, P4)

defect

Tracking

()

RESOLVED FIXED
mozilla30

People

(Reporter: mccr8, Assigned: mccr8)

References

(Blocks 1 open bug)

Details

(Keywords: memory-leak, Whiteboard: [lsan][MemShrink])

Attachments

(1 file)

Easy fix.  I manually audited every |new| in nsComputedDOMStyle.cpp, and the rest look okay to me.
Yup, easy fix; we can just move the |val| decl down below the early returns.

mccr8, did you want to take this? I'll be happy to review, if so; otherwise, I'm happy to take.
(In reply to Daniel Holbert [:dholbert] from comment #1)
> mccr8, did you want to take this?

(missed that you assigned it to yourself; sorry for the unnecessary noise. :))
Priority: -- → P4
Comment on attachment 8389939 [details] [diff] [review]
Don't leak val when we return early from nsComputedDOMStyle::DoGetTextDecoration().

Looks good to me.
Attachment #8389939 - Flags: review+
https://hg.mozilla.org/mozilla-central/rev/ae03abb86737
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla30
You need to log in before you can comment on or make changes to this bug.