Title: [224987] tags/Safari-605.1.14.1/Source/WebCore
- Revision
- 224987
- Author
- [email protected]
- Date
- 2017-11-17 14:12:05 -0800 (Fri, 17 Nov 2017)
Log Message
Cherry-pick r224960. rdar://problem/35485349
Modified Paths
Diff
Modified: tags/Safari-605.1.14.1/Source/WebCore/ChangeLog (224986 => 224987)
--- tags/Safari-605.1.14.1/Source/WebCore/ChangeLog 2017-11-17 22:09:53 UTC (rev 224986)
+++ tags/Safari-605.1.14.1/Source/WebCore/ChangeLog 2017-11-17 22:12:05 UTC (rev 224987)
@@ -1,3 +1,24 @@
+2017-11-17 Jason Marcell <[email protected]>
+
+ Cherry-pick r224960. rdar://problem/35485349
+
+ 2017-11-16 Alex Christensen <[email protected]>
+
+ Fix occasional crash when adding and removing videos
+ https://bugs.webkit.org/show_bug.cgi?id=179792
+
+ Reviewed by Geoffrey Garen.
+
+ In taskCompleted we null out session, and in resume we call _restart on the main thread.
+ If _restart is called after taskCompleted, we want to do nothing.
+ Right now we are calling a method on self.session.loader which is a PlatformMediaResourceLoader&
+ but in ObjC if session is null it will call PlatformMediaResourceLoader::requestResource with a
+ null this pointer, which crashes. Let's not crash.
+
+ * platform/network/cocoa/WebCoreNSURLSession.mm:
+ (-[WebCoreNSURLSessionDataTask _restart]):
+ Early return if we don't have a session.
+
2017-11-16 Jason Marcell <[email protected]>
Cherry-pick r224952. rdar://problem/35581599
Modified: tags/Safari-605.1.14.1/Source/WebCore/platform/network/cocoa/WebCoreNSURLSession.mm (224986 => 224987)
--- tags/Safari-605.1.14.1/Source/WebCore/platform/network/cocoa/WebCoreNSURLSession.mm 2017-11-17 22:09:53 UTC (rev 224986)
+++ tags/Safari-605.1.14.1/Source/WebCore/platform/network/cocoa/WebCoreNSURLSession.mm 2017-11-17 22:12:05 UTC (rev 224987)
@@ -445,6 +445,10 @@
- (void)_restart
{
ASSERT(isMainThread());
+
+ if (!self.session)
+ return;
+
[self _cancel];
_resource = self.session.loader.requestResource(self.originalRequest, PlatformMediaResourceLoader::LoadOption::DisallowCaching);
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes