JS::ContextOptions::ergonomicBrandChecks_ is sometimes used before it is defined
Categories
(Core :: JavaScript Engine, defect)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox91 | --- | fixed |
People
(Reporter: jseward, Assigned: jseward)
Details
Attachments
(3 files)
It appears that (1) JS::ContextOptions::ContextOptions() doesn't give an
initial value for field ergonomicBrandChecks_, and (2) at least in a browser
build, it can be used in that state. A minimal bit of poking around suggests
that it might be defined in shell builds, but not in browser builds.
The result is a bunch of Valgrind complaints in the JS parser, in orExpr.
Doing the obvious thing (setting it to false in
JS::ContextOptions::ContextOptions()) stops Valgrind complaining.
This appears to be related to bug 1648090.
| Assignee | ||
Comment 1•4 years ago
|
||
The obvious fix. I'm not claiming that this is the right fix,
merely that it stops Valgrind complaining.
Comment 2•4 years ago
|
||
The obvious fix looks right. Thanks for looking into this!
Comment 3•4 years ago
|
||
Did you want to land this patch Julian? (otherwise I can)
| Assignee | ||
Comment 4•4 years ago
|
||
It appears that (1) JS::ContextOptions::ContextOptions() doesn't give an
initial value for field ergonomicBrandChecks_, and (2) at least in a browser
build, it can be used in that state. This trivial patch initialises it to
false.
Comment 6•4 years ago
|
||
| bugherder | ||
| Assignee | ||
Updated•4 years ago
|
Description
•