Title: [211520] branches/safari-603-branch/Source/WebCore
Revision
211520
Author
matthew_han...@apple.com
Date
2017-02-01 13:26:47 -0800 (Wed, 01 Feb 2017)

Log Message

Merge r211386. rdar://problem/30204866

Modified Paths

Diff

Modified: branches/safari-603-branch/Source/WebCore/ChangeLog (211519 => 211520)


--- branches/safari-603-branch/Source/WebCore/ChangeLog	2017-02-01 21:26:44 UTC (rev 211519)
+++ branches/safari-603-branch/Source/WebCore/ChangeLog	2017-02-01 21:26:47 UTC (rev 211520)
@@ -1,5 +1,22 @@
 2017-01-31  Matthew Hanson  <matthew_han...@apple.com>
 
+        Merge r211386. rdar://problem/30204866
+
+    2017-01-30  Jer Noble  <jer.no...@apple.com>
+
+            NULL-deref crash at PlatformMediaSession::endInterruption
+            https://bugs.webkit.org/show_bug.cgi?id=167595
+
+            Reviewed by Eric Carlson.
+
+            Use the same, NULL-aware forEachSession() iterator rather than iterating over m_sessions directly.
+
+            * platform/audio/PlatformMediaSessionManager.cpp:
+            (WebCore::PlatformMediaSessionManager::beginInterruption):
+            (WebCore::PlatformMediaSessionManager::endInterruption):
+
+2017-01-31  Matthew Hanson  <matthew_han...@apple.com>
+
         Merge r211337. rdar://problem/30126535
 
     2017-01-28  Zalan Bujtas  <za...@apple.com>

Modified: branches/safari-603-branch/Source/WebCore/platform/audio/PlatformMediaSessionManager.cpp (211519 => 211520)


--- branches/safari-603-branch/Source/WebCore/platform/audio/PlatformMediaSessionManager.cpp	2017-02-01 21:26:44 UTC (rev 211519)
+++ branches/safari-603-branch/Source/WebCore/platform/audio/PlatformMediaSessionManager.cpp	2017-02-01 21:26:47 UTC (rev 211520)
@@ -114,9 +114,9 @@
     LOG(Media, "PlatformMediaSessionManager::beginInterruption");
 
     m_interrupted = true;
-    Vector<PlatformMediaSession*> sessions = m_sessions;
-    for (auto* session : sessions)
-        session->beginInterruption(type);
+    forEachSession([type] (PlatformMediaSession& session, size_t) {
+        session.beginInterruption(type);
+    });
     updateSessionState();
 }
 
@@ -125,9 +125,9 @@
     LOG(Media, "PlatformMediaSessionManager::endInterruption");
 
     m_interrupted = false;
-    Vector<PlatformMediaSession*> sessions = m_sessions;
-    for (auto* session : sessions)
-        session->endInterruption(flags);
+    forEachSession([flags] (PlatformMediaSession& session, size_t) {
+        session.endInterruption(flags);
+    });
 }
 
 void PlatformMediaSessionManager::addSession(PlatformMediaSession& session)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to