mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-25 19:25:43 +00:00
Bug 1214781 - Make oomTest() clear any previous OOM condition r=terrence
This commit is contained in:
parent
5207756269
commit
b35177a4cd
@ -1107,6 +1107,9 @@ OOMTest(JSContext* cx, unsigned argc, Value* vp)
|
||||
return true;
|
||||
}
|
||||
|
||||
MOZ_ASSERT(!cx->isExceptionPending());
|
||||
cx->runtime()->hadOutOfMemory = false;
|
||||
|
||||
RootedFunction function(cx, &args[0].toObject().as<JSFunction>());
|
||||
|
||||
bool verbose = EnvVarIsDefined("OOM_VERBOSE");
|
||||
|
8
js/src/jit-test/tests/gc/bug-1214781.js
Normal file
8
js/src/jit-test/tests/gc/bug-1214781.js
Normal file
@ -0,0 +1,8 @@
|
||||
if (!('oomTest' in this))
|
||||
quit();
|
||||
|
||||
try {
|
||||
gcparam("maxBytes", gcparam("gcBytes"));
|
||||
newGlobal("");
|
||||
} catch (e) {};
|
||||
oomTest(function() {})
|
Loading…
Reference in New Issue
Block a user