Bug 1297565 - Handle failure from calling CompositorBridgeChild::SendNotifyChildCreated() in RenderFrameParent::Init() r=mattwoodrow

This commit is contained in:
George Wright 2016-09-07 14:09:36 -04:00
parent 2f9a23cf41
commit 2e75d2e6ac

View File

@ -120,11 +120,15 @@ RenderFrameParent::Init(nsFrameLoader* aFrameLoader)
// and we'll keep an indirect reference to that tree.
browser->Manager()->AsContentParent()->AllocateLayerTreeId(browser, &mLayersId);
if (lm && lm->AsClientLayerManager()) {
lm->AsClientLayerManager()->GetRemoteRenderer()->SendNotifyChildCreated(mLayersId);
if (!lm->AsClientLayerManager()->GetRemoteRenderer()->SendNotifyChildCreated(mLayersId)) {
return false;
}
}
} else if (XRE_IsContentProcess()) {
ContentChild::GetSingleton()->SendAllocateLayerTreeId(browser->Manager()->ChildID(), browser->GetTabId(), &mLayersId);
CompositorBridgeChild::Get()->SendNotifyChildCreated(mLayersId);
if (!CompositorBridgeChild::Get()->SendNotifyChildCreated(mLayersId)) {
return false;
}
}
mInitted = true;