WebKit Bugzilla
Attachment 359893 Details for
Bug 193723
: REGRESSION (Probably r240243): CrashTracer: WebKitTestRunnerApp at com.apple.WebKit: WebKit::WebResourceLoadStatisticsStore::sendDiagnosticMessageWithValue const + 32
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-193723-20190123085707.patch (text/plain), 4.11 KB, created by
Brent Fulgham
on 2019-01-23 08:57:08 PST
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Brent Fulgham
Created:
2019-01-23 08:57:08 PST
Size:
4.11 KB
patch
obsolete
>Subversion Revision: 240337 >diff --git a/Source/WebKit/ChangeLog b/Source/WebKit/ChangeLog >index b5d93a6b8ea8d9b205eb0a8507687d53a06eae12..9c5273c88310877cf37770d5e82d8b0f712fd093 100644 >--- a/Source/WebKit/ChangeLog >+++ b/Source/WebKit/ChangeLog >@@ -1,3 +1,17 @@ >+2019-01-23 Brent Fulgham <bfulgham@apple.com> >+ >+ REGRESSION (r240243): CrashTracer: WebKitTestRunnerApp at com.apple.WebKit: WebKit::WebResourceLoadStatisticsStore::sendDiagnosticMessageWithValue const + 32 >+ https://bugs.webkit.org/show_bug.cgi?id=193723 >+ <rdar://problem/47476802> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ The new code added in r240243 could attempt to submit telemetry after the relevant >+ WebResourceLoadStatisticsStore was destroyed. We should guard against this possibility. >+ >+ * NetworkProcess/Classifier/WebResourceLoadStatisticsTelemetry.cpp: >+ (WebKit::WebResourceLoadStatisticsTelemetry::calculateAndSubmit): >+ > 2019-01-23 David Kilzer <ddkilzer@apple.com> > > Switch remaining CoreMedia soft-linking in WebKit over to CoreMediaSoftLink.{cpp,h} >diff --git a/Source/WebKit/NetworkProcess/Classifier/WebResourceLoadStatisticsTelemetry.cpp b/Source/WebKit/NetworkProcess/Classifier/WebResourceLoadStatisticsTelemetry.cpp >index da00eb8544a071f45497ea48dfe14f5333b14dd0..9c3139d06ecd22dd4eda6acb04111e222cf7f532 100644 >--- a/Source/WebKit/NetworkProcess/Classifier/WebResourceLoadStatisticsTelemetry.cpp >+++ b/Source/WebKit/NetworkProcess/Classifier/WebResourceLoadStatisticsTelemetry.cpp >@@ -241,16 +241,19 @@ void WebResourceLoadStatisticsTelemetry::calculateAndSubmit(const ResourceLoadSt > } > > // Dispatch on the main thread to make sure the WebPageProxy we're using doesn't go away. >- RunLoop::main().dispatch([sortedPrevalentResources = WTFMove(sortedPrevalentResources), sortedPrevalentResourcesWithoutUserInteraction = WTFMove(sortedPrevalentResourcesWithoutUserInteraction), prevalentResourcesDaysSinceUserInteraction = WTFMove(prevalentResourcesDaysSinceUserInteraction), &resourceLoadStatisticsStore] () { >+ RunLoop::main().dispatch([sortedPrevalentResources = WTFMove(sortedPrevalentResources), sortedPrevalentResourcesWithoutUserInteraction = WTFMove(sortedPrevalentResourcesWithoutUserInteraction), prevalentResourcesDaysSinceUserInteraction = WTFMove(prevalentResourcesDaysSinceUserInteraction), resourceLoadStatisticsStore = makeWeakPtr(resourceLoadStatisticsStore)] () { >+ if (!resourceLoadStatisticsStore) >+ return; >+ > auto webPageProxy = WebPageProxy::nonEphemeralWebPageProxy(); > if (!webPageProxy) { > if (notifyPagesWhenTelemetryWasCaptured) >- notifyPages(0, 0, 0, resourceLoadStatisticsStore.store()); >+ notifyPages(0, 0, 0, resourceLoadStatisticsStore->store()); > return; > } > > if (notifyPagesWhenTelemetryWasCaptured) { >- notifyPages(sortedPrevalentResources, sortedPrevalentResourcesWithoutUserInteraction, prevalentResourcesDaysSinceUserInteraction.size(), resourceLoadStatisticsStore.store()); >+ notifyPages(sortedPrevalentResources, sortedPrevalentResourcesWithoutUserInteraction, prevalentResourcesDaysSinceUserInteraction.size(), resourceLoadStatisticsStore->store()); > // The notify pages function is for testing so we don't need to do an actual submission. > return; > } >@@ -263,7 +266,7 @@ void WebResourceLoadStatisticsTelemetry::calculateAndSubmit(const ResourceLoadSt > if (prevalentResourcesDaysSinceUserInteraction.size() > 1) > webPageProxy->logDiagnosticMessageWithValue(DiagnosticLoggingKeys::resourceLoadStatisticsTelemetryKey(), "medianPrevalentResourcesWithUserInteractionDaysSinceUserInteraction"_s, median(prevalentResourcesDaysSinceUserInteraction), significantFiguresForLoggedValues, ShouldSample::No); > >- submitTopLists(sortedPrevalentResources, sortedPrevalentResourcesWithoutUserInteraction, resourceLoadStatisticsStore.store()); >+ submitTopLists(sortedPrevalentResources, sortedPrevalentResourcesWithoutUserInteraction, resourceLoadStatisticsStore->store()); > }); > } >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 193723
: 359893