Make BackgroundImpl optional in the GPU process. (bug 1294350 part 7, r=billm)

This commit is contained in:
David Anderson 2016-08-22 22:57:36 -07:00
parent 398cf04082
commit 44a97e25c9

View File

@ -1761,8 +1761,10 @@ ChildImpl::SynchronouslyCreateForCurrentThread()
void
ChildImpl::CloseForCurrentThread()
{
MOZ_ASSERT(sThreadLocalIndex != kBadThreadLocalIndex,
"BackgroundChild::Startup() was never called!");
if (sThreadLocalIndex == kBadThreadLocalIndex) {
return;
}
auto threadLocalInfo =
static_cast<ThreadLocalInfo*>(PR_GetThreadPrivate(sThreadLocalIndex));