Bug 502687 - GCGraphBuilder::AddNode crashes on OOM. r=dbaron

This commit is contained in:
Blake Kaplan 2009-07-16 13:06:48 -07:00
parent 96a04e8df6
commit c333b464ab

View File

@ -1336,6 +1336,9 @@ GCGraphBuilder::AddNode(void *s, nsCycleCollectionParticipant *aParticipant
)
{
PtrToNodeEntry *e = static_cast<PtrToNodeEntry*>(PL_DHashTableOperate(&mPtrToNodeMap, s, PL_DHASH_ADD));
if (!e)
return nsnull;
PtrInfo *result;
if (!e->mNode) {
// New entry.