mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-29 15:52:07 +00:00
Bug 911216 - Fix crashes caused by not properly handling not having an object at all as the target promise in EnqueuePromiseReactionJob, on a CLOSED TREE. r=bustage
This commit is contained in:
parent
0b68c0c6df
commit
98a17b460b
@ -642,7 +642,7 @@ EnqueuePromiseReactionJob(JSContext* cx, HandleValue handler_, HandleValue handl
|
||||
// handler's compartment above, because we should pass objects from a
|
||||
// single compartment to the enqueuePromiseJob callback.
|
||||
RootedObject promise(cx);
|
||||
if (promise_->is<PromiseObject>()) {
|
||||
if (promise_ && promise_->is<PromiseObject>()) {
|
||||
promise = promise_;
|
||||
if (!cx->compartment()->wrap(cx, &promise))
|
||||
return false;
|
||||
|
Loading…
Reference in New Issue
Block a user