зеркало из https://github.com/mozilla/pjs.git
Add null ptr checks to avoid crashing, this fixes #30372. r=av@netscape.com
This commit is contained in:
Родитель
72ad6e26bf
Коммит
70f4a36661
|
@ -87,12 +87,16 @@ nsEvaluateStringProxy::Init(nsIChannel* channel)
|
|||
NS_IMETHODIMP
|
||||
nsEvaluateStringProxy::EvaluateString(char **aRetValue, PRBool *aIsUndefined)
|
||||
{
|
||||
NS_ENSURE_ARG_POINTER(mChannel);
|
||||
NS_ENSURE_ARG_POINTER(aRetValue);
|
||||
NS_ENSURE_ARG_POINTER(aIsUndefined);
|
||||
|
||||
nsresult rv;
|
||||
|
||||
NS_ENSURE_ARG_POINTER(mChannel);
|
||||
nsCOMPtr<nsIInterfaceRequestor> callbacks;
|
||||
rv = mChannel->GetNotificationCallbacks(getter_AddRefs(callbacks));
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
NS_ENSURE_TRUE(callbacks, NS_ERROR_FAILURE);
|
||||
|
||||
// The event sink must be a script global Object Owner or we fail.
|
||||
nsCOMPtr<nsIScriptGlobalObjectOwner> globalOwner;
|
||||
|
|
Загрузка…
Ссылка в новой задаче