mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 838955 (part 1) - Fix rooting hazards in jsstr.cpp identified by static analysis. r=sfink.
--HG-- extra : rebase_source : cc45015a1840ccb1c3146e0b4ad81f2226dac985
This commit is contained in:
parent
19635937ba
commit
e752d42de8
@ -2043,7 +2043,8 @@ FindReplaceLength(JSContext *cx, RegExpStatics *res, ReplaceData &rdata, size_t
|
|||||||
rdata.elembase = NULL;
|
rdata.elembase = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (JSObject *lambda = rdata.lambda) {
|
if (rdata.lambda) {
|
||||||
|
RootedObject lambda(cx, rdata.lambda);
|
||||||
PreserveRegExpStatics staticsGuard(cx, res);
|
PreserveRegExpStatics staticsGuard(cx, res);
|
||||||
if (!staticsGuard.init(cx))
|
if (!staticsGuard.init(cx))
|
||||||
return false;
|
return false;
|
||||||
|
Loading…
Reference in New Issue
Block a user