mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 562442: Plugin crash fix (parent process). r=jmathies
This commit is contained in:
parent
b128768901
commit
f1269e3c00
@ -827,8 +827,13 @@ nsObjectFrame::CallSetWindow(bool aCheckIsHidden)
|
||||
window->width = intBounds.width;
|
||||
window->height = intBounds.height;
|
||||
|
||||
// this will call pi->SetWindow and take care of window subclassing
|
||||
// if needed, see bug 132759.
|
||||
// Calling SetWindow might destroy this frame. We need to use the instance
|
||||
// owner to clean up so hold a ref.
|
||||
nsRefPtr<nsPluginInstanceOwner> instanceOwnerRef(mInstanceOwner);
|
||||
|
||||
// This will call pi->SetWindow and take care of window subclassing
|
||||
// if needed, see bug 132759. Calling SetWindow can destroy this frame
|
||||
// so check for that before doing anything else with this frame's memory.
|
||||
if (mInstanceOwner->UseAsyncRendering()) {
|
||||
rv = pi->AsyncSetWindow(window);
|
||||
}
|
||||
@ -836,7 +841,8 @@ nsObjectFrame::CallSetWindow(bool aCheckIsHidden)
|
||||
rv = window->CallSetWindow(pi);
|
||||
}
|
||||
|
||||
mInstanceOwner->ReleasePluginPort(window->window);
|
||||
instanceOwnerRef->ReleasePluginPort(window->window);
|
||||
|
||||
return rv;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user