Closed Bug 1231130 Opened 4 years ago Closed 4 years ago

[Static Analysis][Uninitialized scalar field] Function nsPluginTag::nsPluginTag from nsPluginTags.h

Categories

(Core :: Plug-ins, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla47
Tracking Status
firefox45 --- affected
firefox47 --- fixed

People

(Reporter: andi, Assigned: andi)

References

(Blocks 1 open bug)

Details

(Keywords: coverity, Whiteboard: CID 1327956)

Attachments

(1 file, 1 obsolete file)

The Static Analysis tool Coverity added that mHadLocalInstance is not initialized in the constructor, thus containing garbage value.
Attached patch Bug 1231130.diff (obsolete) — Splinter Review
Hello Josh,

Can you please take a look other this patch?

THX
Attachment #8696682 - Flags: review?(jaas)
Comment on attachment 8696682 [details] [diff] [review]
Bug 1231130.diff

Review of attachment 8696682 [details] [diff] [review]:
-----------------------------------------------------------------

This looks good but there is are three nsPluginTag constructors in that file. The first already initializes mHadLocalInstance. Your patch fixes the third, but the second one doesn't initialize mHadLocalInstance either - why didn't you fix the second one?
Attachment #8696682 - Attachment is obsolete: true
Attachment #8696682 - Flags: review?(jaas)
Attachment #8716205 - Flags: review?(jaas) → review+
Keywords: checkin-needed
has problems to apply:

Hunk #1 succeeded at 263 with fuzz 2 (offset 1 lines).
Hunk #2 FAILED at 295
1 out of 2 hunks FAILED -- saving rejects to file dom/plugins/base/nsPluginTags.cpp.rej
Flags: needinfo?(bogdan.postelnicu)
Keywords: checkin-needed
pushed it to mozilla-inbound, thank you Carsten
Flags: needinfo?(bogdan.postelnicu)
https://hg.mozilla.org/mozilla-central/rev/430e054e6a0f
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla47
You need to log in before you can comment on or make changes to this bug.