Bug 1087464, Use the correct ContentParent when Nuwa forks PBackground actors. r=khuey.

This commit is contained in:
Ben Turner 2014-10-23 20:13:25 -04:00
parent f3c9b8625c
commit 09dd36a3d7

View File

@ -1347,6 +1347,7 @@ ParentImpl::CloneToplevel(const InfallibleTArray<ProtocolFdMapping>& aFds,
{
AssertIsInMainProcess();
AssertIsOnMainThread();
MOZ_ASSERT(aCtx->GetContentParent());
const ProtocolId protocolId = GetProtocolId();
@ -1363,7 +1364,7 @@ ParentImpl::CloneToplevel(const InfallibleTArray<ProtocolFdMapping>& aFds,
}
PBackgroundParent* clonedActor =
Alloc(mContent, transport, base::GetProcId(aPeerProcess));
Alloc(aCtx->GetContentParent(), transport, base::GetProcId(aPeerProcess));
MOZ_ASSERT(clonedActor);
clonedActor->CloneManagees(this, aCtx);