[iOS WebKit2] Don't uninstall the memory pressure listener after first signal.
authorakling@apple.com <akling@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 10 Jul 2014 22:26:02 +0000 (22:26 +0000)
committerakling@apple.com <akling@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 10 Jul 2014 22:26:02 +0000 (22:26 +0000)
<https://webkit.org/b/134814>

The call to uninstall() should not be made on iOS since iOS doesn't use the
hold-off mechanism in MemoryPressureHandler.

Reviewed by Benjamin Poulain.

* platform/cocoa/MemoryPressureHandlerCocoa.mm:
(WebCore::MemoryPressureHandler::respondToMemoryPressure):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@170978 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/platform/cocoa/MemoryPressureHandlerCocoa.mm

index 488440b..854c65f 100644 (file)
@@ -1,3 +1,16 @@
+2014-07-10  Andreas Kling  <akling@apple.com>
+
+        [iOS WebKit2] Don't uninstall the memory pressure listener after first signal.
+        <https://webkit.org/b/134814>
+
+        The call to uninstall() should not be made on iOS since iOS doesn't use the
+        hold-off mechanism in MemoryPressureHandler.
+
+        Reviewed by Benjamin Poulain.
+
+        * platform/cocoa/MemoryPressureHandlerCocoa.mm:
+        (WebCore::MemoryPressureHandler::respondToMemoryPressure):
+
 2014-07-10  Jer Noble  <jer.noble@apple.com>
 
         [MSE] Overlapping appended ranges must cause the decoder to flush and re-enqueue.
index a733eaa..804250a 100644 (file)
@@ -176,9 +176,8 @@ void MemoryPressureHandler::holdOff(unsigned seconds)
 
 void MemoryPressureHandler::respondToMemoryPressure(bool critical)
 {
-    uninstall();
-
 #if !PLATFORM(IOS)
+    uninstall();
     double startTime = monotonicallyIncreasingTime();
 #endif