Bug 452485. wrong check for oom during hardward callback. r=stuart
authorDoug Turner <dougt@meer.net>
Wed, 27 Aug 2008 06:36:57 -0700
changeset 18471 da8d9208b532049355ec88370453e140b9aeb948
parent 18470 5adc6249494207caf38643374e726b9eab08355e
child 18472 b0b7959491f6ff0873fdaf3d320c51096306a56b
push idunknown
push userunknown
push dateunknown
reviewersstuart
bugs452485
milestone1.9.1a2pre
Bug 452485. wrong check for oom during hardward callback. r=stuart
toolkit/xre/nsNativeAppSupportUnix.cpp
--- a/toolkit/xre/nsNativeAppSupportUnix.cpp
+++ b/toolkit/xre/nsNativeAppSupportUnix.cpp
@@ -221,19 +221,19 @@ static void OssoHardwareCallback(osso_hw
   osso_hw_state_t* ourState = (osso_hw_state_t*) data;
 
   if (state->shutdown_ind) {
     nsCOMPtr<nsIAppStartup> appService =  do_GetService("@mozilla.org/toolkit/app-startup;1");
     if (appService)
       appService->Quit(nsIAppStartup::eForceQuit);
     return;
   }
-    
+
   if (state->memory_low_ind) {
-    if (ourState->memory_low_ind) {
+      if (! ourState->memory_low_ind) {
       nsCOMPtr<nsIObserverService> os = do_GetService("@mozilla.org/observer-service;1");
       if (os)
         os->NotifyObservers(nsnull, "memory-pressure", NS_LITERAL_STRING("low-memory").get());
     }
   }
   
   if (state->system_inactivity_ind != ourState->system_inactivity_ind) {
       nsCOMPtr<nsIObserverService> os = do_GetService("@mozilla.org/observer-service;1");