Bug 1085662 - Don't crash if there is no deadlock detector when destroying BlockingResourceBase r=froydnj

This commit is contained in:
James Willcox 2014-10-21 10:16:31 -05:00
parent 8d41065e55
commit 33ff0dac10

View File

@ -229,7 +229,9 @@ BlockingResourceBase::~BlockingResourceBase()
// base class, or its underlying primitive, will check for such
// stupid mistakes.
mChainPrev = 0; // racy only for stupidly buggy client code
sDeadlockDetector->Remove(this);
if (sDeadlockDetector) {
sDeadlockDetector->Remove(this);
}
}