Closed Bug 1245099 Opened 8 years ago Closed 8 years ago

Address a compilation maybe-uninitialized warning

Categories

(Core :: XPCOM, defect)

47 Branch
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla47
Tracking Status
firefox47 --- fixed

People

(Reporter: paul.bignier, Assigned: paul.bignier)

References

Details

Attachments

(1 file)

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Firefox/38.0
Build ID: 20160127060627

Steps to reproduce:

'./mach build' in the gecko repo


Actual results:

Got a [-Wmaybe-uninitialized] warning in xpcom


Expected results:

No warning
Attachment #8714794 - Flags: review?(benjamin)
Comment on attachment 8714794 [details] [diff] [review]
0001-Fixed-uninitialized-variable-warning.patch

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

When fixing build warnings, it's helpful to cite the actual build warning in the bug, rather than just saying "there was a warning."  It's clear that you're fixing an uninitialized variable warning related to |value|; it's not clear what's causing the actual warning.

I think the code is smarter than the compiler here, but we might as well initialize it just to make compilation quieter.
Attachment #8714794 - Flags: review?(benjamin) → review+
Thanks for the patch!  I've marked your patch as needing checkin; somebody will be along to check it in relatively soon.

(Note to said person: this patch is simple enough it doesn't need a try run for checkin-needed.  I've verified that it compiles locally.)
Assignee: nobody → paul.bignier
Blocks: buildwarning
Status: UNCONFIRMED → NEW
Ever confirmed: true
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/c409ce7c06a4
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla47
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: