[CoordinatedGraphics] ASSERTION FAILED: !m_state.isSuspended
authorHironori.Fujii@sony.com <Hironori.Fujii@sony.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 12 Mar 2019 04:12:32 +0000 (04:12 +0000)
committerHironori.Fujii@sony.com <Hironori.Fujii@sony.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 12 Mar 2019 04:12:32 +0000 (04:12 +0000)
https://bugs.webkit.org/show_bug.cgi?id=195550

Reviewed by Carlos Garcia Campos.

CompositingRunLoop::suspend() locks a mutex and stops the update
timer. But, the timer can be fired after the lock was acquired and
before the timer is stopped.

* Shared/CoordinatedGraphics/threadedcompositor/CompositingRunLoop.cpp:
(WebKit::CompositingRunLoop::updateTimerFired): Removed the
assertion. Return early if m_state.isSuspended.

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

Source/WebKit/ChangeLog
Source/WebKit/Shared/CoordinatedGraphics/threadedcompositor/CompositingRunLoop.cpp

index 9253ca1..935443e 100644 (file)
@@ -1,3 +1,18 @@
+2019-03-11  Fujii Hironori  <Hironori.Fujii@sony.com>
+
+        [CoordinatedGraphics] ASSERTION FAILED: !m_state.isSuspended
+        https://bugs.webkit.org/show_bug.cgi?id=195550
+
+        Reviewed by Carlos Garcia Campos.
+
+        CompositingRunLoop::suspend() locks a mutex and stops the update
+        timer. But, the timer can be fired after the lock was acquired and
+        before the timer is stopped.
+
+        * Shared/CoordinatedGraphics/threadedcompositor/CompositingRunLoop.cpp:
+        (WebKit::CompositingRunLoop::updateTimerFired): Removed the
+        assertion. Return early if m_state.isSuspended.
+
 2019-03-11  Per Arne Vollan  <pvollan@apple.com>
 
         [macOS] Remove the Kerberos rules from the WebContent sandbox
index 87c6ee8..c8084bd 100644 (file)
@@ -222,7 +222,8 @@ void CompositingRunLoop::updateTimerFired()
     {
         // Both composition and scene update are now in progress.
         LockHolder locker(m_state.lock);
-        ASSERT(!m_state.isSuspended);
+        if (m_state.isSuspended)
+            return;
         m_state.composition = CompositionState::InProgress;
         m_state.update = UpdateState::InProgress;
     }