Title: [230777] tags/Safari-606.1.14/Source/WebKit
- Revision
- 230777
- Author
- [email protected]
- Date
- 2018-04-18 13:26:57 -0700 (Wed, 18 Apr 2018)
Log Message
Cherry-pick r230771. rdar://problem/39287964
Avoid crash if ITP Debug mode is on, but ResourceLoadStatistics are not being used
https://bugs.webkit.org/show_bug.cgi?id=184739
<rdar://problem/39287964>
Reviewed by David Kilzer.
If a user has the ResourceLoadStatistics logic turned off, but has the ITP Debug experimental
flag turned on, you can cause a crash.
This is because the WebsiteDataStore for the process doesn't bother creating a ResourceLoadStatisticsStore
if the statistics machinery is not running. The ITP debug flag was being blindly set without checking
if the statistics store exists or not, which can cause a crash.
* UIProcess/WebsiteData/WebsiteDataStore.cpp:
(WebKit::WebsiteDataStore::setResourceLoadStatisticsDebugMode): Check if the statistics store exists
before calling functions on it.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@230771 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Modified Paths
Diff
Modified: tags/Safari-606.1.14/Source/WebKit/ChangeLog (230776 => 230777)
--- tags/Safari-606.1.14/Source/WebKit/ChangeLog 2018-04-18 20:19:55 UTC (rev 230776)
+++ tags/Safari-606.1.14/Source/WebKit/ChangeLog 2018-04-18 20:26:57 UTC (rev 230777)
@@ -1,5 +1,48 @@
2018-04-18 Kocsen Chung <[email protected]>
+ Cherry-pick r230771. rdar://problem/39287964
+
+ Avoid crash if ITP Debug mode is on, but ResourceLoadStatistics are not being used
+ https://bugs.webkit.org/show_bug.cgi?id=184739
+ <rdar://problem/39287964>
+
+ Reviewed by David Kilzer.
+
+ If a user has the ResourceLoadStatistics logic turned off, but has the ITP Debug experimental
+ flag turned on, you can cause a crash.
+
+ This is because the WebsiteDataStore for the process doesn't bother creating a ResourceLoadStatisticsStore
+ if the statistics machinery is not running. The ITP debug flag was being blindly set without checking
+ if the statistics store exists or not, which can cause a crash.
+
+ * UIProcess/WebsiteData/WebsiteDataStore.cpp:
+ (WebKit::WebsiteDataStore::setResourceLoadStatisticsDebugMode): Check if the statistics store exists
+ before calling functions on it.
+
+
+ git-svn-id: https://svn.webkit.org/repository/webkit/trunk@230771 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+ 2018-04-18 Brent Fulgham <[email protected]>
+
+ Avoid crash if ITP Debug mode is on, but ResourceLoadStatistics are not being used
+ https://bugs.webkit.org/show_bug.cgi?id=184739
+ <rdar://problem/39287964>
+
+ Reviewed by David Kilzer.
+
+ If a user has the ResourceLoadStatistics logic turned off, but has the ITP Debug experimental
+ flag turned on, you can cause a crash.
+
+ This is because the WebsiteDataStore for the process doesn't bother creating a ResourceLoadStatisticsStore
+ if the statistics machinery is not running. The ITP debug flag was being blindly set without checking
+ if the statistics store exists or not, which can cause a crash.
+
+ * UIProcess/WebsiteData/WebsiteDataStore.cpp:
+ (WebKit::WebsiteDataStore::setResourceLoadStatisticsDebugMode): Check if the statistics store exists
+ before calling functions on it.
+
+2018-04-18 Kocsen Chung <[email protected]>
+
Cherry-pick r230747. rdar://problem/39468022
WebKit::DisplayLink maintains a strong reference to WebPageProxy, creating a reference cycle
Modified: tags/Safari-606.1.14/Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp (230776 => 230777)
--- tags/Safari-606.1.14/Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp 2018-04-18 20:19:55 UTC (rev 230776)
+++ tags/Safari-606.1.14/Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp 2018-04-18 20:26:57 UTC (rev 230777)
@@ -1435,7 +1435,8 @@
void WebsiteDataStore::setResourceLoadStatisticsDebugMode(bool enabled)
{
m_resourceLoadStatisticsDebugMode = enabled;
- m_resourceLoadStatistics->setResourceLoadStatisticsDebugMode(enabled);
+ if (m_resourceLoadStatistics)
+ m_resourceLoadStatistics->setResourceLoadStatisticsDebugMode(enabled);
}
void WebsiteDataStore::enableResourceLoadStatisticsAndSetTestingCallback(Function<void (const String&)>&& callback)
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes