Fixing bug 411082. Fix top crash bug due to us calling into scriptable helper code w/o pushing a JS context on the stack. r+sr=jonas@sicking.cc

This commit is contained in:
2008-01-10 13:46:33 -08:00
parent 6db984a50a
commit 71272035ad
2 changed files with 8 additions and 4 deletions

View File

@@ -1654,10 +1654,13 @@ nsObjectFrame::NotifyContentObjectWrapper()
if (NS_FAILED(rv))
return;
// Abuse the scriptable helper to trigger prototype setup for the
// wrapper for mContent so that this plugin becomes part of the DOM
// object.
helper->PostCreate(wrapper, cx, obj);
nsCxPusher cxPusher;
if (cxPusher.Push(mContent)) {
// Abuse the scriptable helper to trigger prototype setup for the
// wrapper for mContent so that this plugin becomes part of the DOM
// object.
helper->PostCreate(wrapper, cx, obj);
}
}
// static