Closed Bug 1230135 Opened 4 years ago Closed 4 years ago

[Static Analysis][Dereference Null Return Value] Function DOMSVGPathSegList::InsertItemBefore from DOMSVGPathSegList.cpp

Categories

(Core :: SVG, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla45
Tracking Status
firefox45 --- fixed

People

(Reporter: andi, Assigned: andi)

References

(Blocks 1 open bug)

Details

(Keywords: coverity, Whiteboard: CID 1338372 )

Attachments

(1 file)

The Static Analysis tool Scan-Build added value returned by GetDOMWrapperIfExists(InternalAList().GetAnimValKey()) to variable animVal can be NULL leading to a potential null pointer dereference later on.
Whiteboard: CID 1338372
Attached patch Bug 1230135.diffSplinter Review
Hello Jonathan,

Could you please take a look other this patch?

THX
Attachment #8695278 - Flags: review?(jwatt)
Comment on attachment 8695278 [details] [diff] [review]
Bug 1230135.diff

stealing as this is my code.

MOZ_ASSERT(animVal, "AnimListMirrorsBaseList() promised a non-null animVal");

would be better but the text doesn't matter that much.
Attachment #8695278 - Flags: review?(jwatt) → review+
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/949161bdd28a
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla45
You need to log in before you can comment on or make changes to this bug.