Bug 940505 - Fix rooting hazard in JSObject2JSObjectMap::Add() r=bholley

This commit is contained in:
Jon Coppeard 2013-11-20 15:37:30 +00:00
parent 9a6ba361f7
commit 8e2bf74b90

View File

@ -646,7 +646,7 @@ public:
return p->value;
if (!mTable.add(p, key, value))
return nullptr;
MOZ_ASSERT(xpc::GetObjectScope(key)->mWaiverWrapperMap == this);
MOZ_ASSERT(xpc::GetCompartmentPrivate(key)->scope->mWaiverWrapperMap == this);
JS_StoreObjectPostBarrierCallback(cx, KeyMarkCallback, key, this);
return value;
}