mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 634752 - Always drop jsPrincipals before returning from LoadSubScript, r+a=jst
This commit is contained in:
parent
94bec0d5a6
commit
6b366b61a3
@ -392,6 +392,7 @@ mozJSSubScriptLoader::LoadSubScript (const PRUnichar * aURL
|
||||
|
||||
if (NS_FAILED(rv))
|
||||
{
|
||||
JSPRINCIPALS_DROP(cx, jsPrincipals);
|
||||
errmsg = JS_NewStringCopyZ(cx, LOAD_ERROR_BADCHARSET);
|
||||
goto return_exception;
|
||||
}
|
||||
@ -405,6 +406,8 @@ mozJSSubScriptLoader::LoadSubScript (const PRUnichar * aURL
|
||||
buf, len, uriStr.get(), 1, rval);
|
||||
}
|
||||
|
||||
JSPRINCIPALS_DROP(cx, jsPrincipals);
|
||||
|
||||
if (ok)
|
||||
{
|
||||
JSAutoEnterCompartment rac;
|
||||
@ -417,8 +420,6 @@ mozJSSubScriptLoader::LoadSubScript (const PRUnichar * aURL
|
||||
JS_SetErrorReporter (cx, er);
|
||||
|
||||
cc->SetReturnValueWasSet (ok);
|
||||
|
||||
JSPRINCIPALS_DROP(cx, jsPrincipals);
|
||||
return NS_OK;
|
||||
|
||||
return_exception:
|
||||
|
Loading…
Reference in New Issue
Block a user