diff options
author | bors-servo <lbergstrom+bors@mozilla.com> | 2020-03-06 05:20:26 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-06 05:20:26 -0500 |
commit | 356c4e0bc860307ca373f85156e816f8c0a0d132 (patch) | |
tree | 9b3b23a7518ce5bd9c425ecb725886b60e308d05 /components/script/dom/bindings/error.rs | |
parent | ca25e18791163de5c6af1267d876c7f5bb705f61 (diff) | |
parent | 5a4f8cf93f9f674a164a0a3cfc586accef3d06f9 (diff) | |
download | servo-356c4e0bc860307ca373f85156e816f8c0a0d132.tar.gz servo-356c4e0bc860307ca373f85156e816f8c0a0d132.zip |
Auto merge of #25678 - servo:smup, r=asajeffrey
Update SpiderMonkey
Do not merge.
Diffstat (limited to 'components/script/dom/bindings/error.rs')
-rw-r--r-- | components/script/dom/bindings/error.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/components/script/dom/bindings/error.rs b/components/script/dom/bindings/error.rs index b88a6cabed3..f678611423b 100644 --- a/components/script/dom/bindings/error.rs +++ b/components/script/dom/bindings/error.rs @@ -19,6 +19,7 @@ use crate::script_runtime::JSContext as SafeJSContext; #[cfg(feature = "js_backtrace")] use backtrace::Backtrace; use js::error::{throw_range_error, throw_type_error}; +use js::jsapi::ExceptionStackBehavior; use js::jsapi::JSContext; use js::jsapi::JS_ClearPendingException; use js::jsapi::JS_IsExceptionPending; @@ -161,7 +162,7 @@ pub fn throw_dom_exception(cx: SafeJSContext, global: &GlobalScope, result: Erro let exception = DOMException::new(global, code); rooted!(in(*cx) let mut thrown = UndefinedValue()); exception.to_jsval(*cx, thrown.handle_mut()); - JS_SetPendingException(*cx, thrown.handle()); + JS_SetPendingException(*cx, thrown.handle(), ExceptionStackBehavior::Capture); } } |