Bug 506838 - Deal with GetCxSubjectPrincipalAndFrame returning a non-scripted frame. r+sr=jst

This commit is contained in:
Blake Kaplan 2009-08-10 18:07:47 -07:00
parent 9515b85185
commit 7b08162c95
2 changed files with 4 additions and 0 deletions

View File

@ -5027,6 +5027,8 @@ nsContentUtils::CanAccessNativeAnon()
// Some code is running, we can't make the assumption, as above, but we
// can't use a native frame, so clear fp.
fp = nsnull;
} else if (!fp->script) {
fp = nsnull;
}
void *annotation = fp ? JS_GetFrameAnnotation(cx, fp) : nsnull;

View File

@ -185,6 +185,8 @@ AllowedToAct(JSContext *cx, jsval idval)
// Some code is running, we can't make the assumption, as above, but we
// can't use a native frame, so clear fp.
fp = nsnull;
} else if (!fp->script) {
fp = nsnull;
}
void *annotation = fp ? JS_GetFrameAnnotation(cx, fp) : nsnull;