check for existance before dereferencing

git-svn-id: svn://10.0.0.236/trunk@30469 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
sspitzer%netscape.com
1999-05-06 00:24:45 +00:00
parent f9d569e01f
commit 5f83d6c89a
2 changed files with 8 additions and 4 deletions

View File

@@ -78,8 +78,10 @@ EventQueueStack::EventQueueStack(EventQueueStack* next)
mEventQueue = NULL;
}
if (NS_FAILED(mEventQueue->Init()))
mEventQueue = NULL;
if (mEventQueue) {
if (NS_FAILED(mEventQueue->Init()))
mEventQueue = NULL;
}
}
EventQueueStack::~EventQueueStack()