Bug 1101416 - Don't assert against pending exceptions in AutoNoJSAPI. r=luke,r=smaug
authorBobby Holley <bobbyholley@gmail.com>
Wed, 17 Dec 2014 16:34:37 -0800
changeset 246124 51ea551dd2663b51688104d41f3592472a08c77c
parent 246123 571e6519a2a6380b5daf51c233b477b1095e3203
child 246125 d302447734acae0f714e37f379eccb8ed348edde
push id4489
push userraliiev@mozilla.com
push dateMon, 23 Feb 2015 15:17:55 +0000
treeherdermozilla-beta@fd7c3dc24146 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersluke, smaug
bugs1101416
milestone37.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1101416 - Don't assert against pending exceptions in AutoNoJSAPI. r=luke,r=smaug
dom/base/ScriptSettings.cpp
--- a/dom/base/ScriptSettings.cpp
+++ b/dom/base/ScriptSettings.cpp
@@ -564,18 +564,16 @@ AutoIncumbentScript::AutoIncumbentScript
   : ScriptSettingsStackEntry(aGlobalObject, /* aCandidate = */ false)
   , mCallerOverride(nsContentUtils::GetCurrentJSContextForThread())
 {
 }
 
 AutoNoJSAPI::AutoNoJSAPI(bool aIsMainThread)
   : ScriptSettingsStackEntry()
 {
-  MOZ_ASSERT_IF(nsContentUtils::GetCurrentJSContextForThread(),
-                !JS_IsExceptionPending(nsContentUtils::GetCurrentJSContextForThread()));
   if (aIsMainThread) {
     mCxPusher.emplace(static_cast<JSContext*>(nullptr),
                       /* aAllowNull = */ true);
   }
 }
 
 danger::AutoCxPusher::AutoCxPusher(JSContext* cx, bool allowNull)
 {