Bug 632341 - Fix bogus assertion in the case where there is no sensor.dll. ASSERTION: Shutdown called when mLibrary is null. r=blassey

This commit is contained in:
Doug Turner 2011-07-16 22:15:21 -07:00
parent 4c7c7773bc
commit 84ab5686cf

View File

@ -98,7 +98,9 @@ ThinkPadSensor::Startup()
void
ThinkPadSensor::Shutdown()
{
NS_ASSERTION(mLibrary, "Shutdown called when mLibrary is null?");
if (mLibrary == nsnull)
return;
FreeLibrary(mLibrary);
mLibrary = nsnull;
gShockproofGetAccelerometerData = nsnull;