Bug 1174487. Stop using JS_ReportPendingException in ThrowAndReport. Just let the AutoJSAPI do the work for us. r=bholley

This commit is contained in:
Boris Zbarsky 2015-06-15 20:11:54 -04:00
parent 3437c1a714
commit 524cf12ad9

View File

@ -142,9 +142,9 @@ ThrowAndReport(nsPIDOMWindow* aWindow, nsresult aRv, const char* aMessage)
if (NS_WARN_IF(!jsapi.InitWithLegacyErrorReporting(aWindow))) {
return;
}
jsapi.TakeOwnershipOfErrorReporting();
Throw(jsapi.cx(), aRv, aMessage);
(void) JS_ReportPendingException(jsapi.cx());
}
already_AddRefed<Exception>