Closed
Bug 1125698
Opened 10 years ago
Closed 10 years ago
js/src/jscntxt.cpp:862:74: warning: variable 'dummy' is uninitialized when used here [-Wuninitialized]
Categories
(Core :: JavaScript Engine, defect)
Tracking
()
RESOLVED
FIXED
mozilla40
Tracking | Status | |
---|---|---|
firefox40 | --- | fixed |
People
(Reporter: cpeterson, Assigned: cpeterson)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
10.53 KB,
patch
|
Waldo
:
review+
|
Details | Diff | Splinter Review |
clang warns that js_ReportErrorNumberUCArray() passes va_list dummy to js_ExpandErrorArguments() without having initialized dummy with va_start. However, js_ReportErrorNumberUCArray() is not a variadic function, so it can't call va_start() itself without clang emitting a -Wvarargs warning.
js/src/jscntxt.cpp:862:74: warning: variable 'dummy' is uninitialized when used here [-Wuninitialized]
Assignee | ||
Comment 1•10 years ago
|
||
1. Add ExpandErrorArguments() varargs helper function and remove uninitialized `dummy` va_list variable.
2. Rename original ExpandErrorArguments() function to ExpandErrorArgumentsVA() like other SpiderMonkey functions that take a va_list parameter (and to differentiate it from the new helper function).
https://treeherder.mozilla.org/#/jobs?repo=try&revision=97a6af09b2a6
Assignee: nobody → cpeterson
Status: NEW → ASSIGNED
Attachment #8584954 -
Flags: review?(jwalden+bmo)
Updated•10 years ago
|
Attachment #8584954 -
Flags: review?(jwalden+bmo) → review+
Assignee | ||
Comment 2•10 years ago
|
||
Thanks. I believe this was the last -Wuninitialized from clang and gcc in mozilla-central.
https://hg.mozilla.org/integration/mozilla-inbound/rev/f5782f959c94
Comment 3•10 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
status-firefox40:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla40
You need to log in
before you can comment on or make changes to this bug.
Description
•