Modified: trunk/Source/WebKit/ChangeLog (264320 => 264321)
--- trunk/Source/WebKit/ChangeLog 2020-07-13 22:12:59 UTC (rev 264320)
+++ trunk/Source/WebKit/ChangeLog 2020-07-13 22:31:53 UTC (rev 264321)
@@ -1,3 +1,14 @@
+2020-07-13 Chris Dumez <[email protected]>
+
+ Add more logging for navigation policy decisions on UIProcess side
+ https://bugs.webkit.org/show_bug.cgi?id=214277
+
+ Reviewed by Geoffrey Garen.
+
+ * UIProcess/WebPageProxy.cpp:
+ (WebKit::WebPageProxy::receivedNavigationPolicyDecision):
+ (WebKit::WebPageProxy::decidePolicyForNavigationAction):
+
2020-07-13 Ryan Haddad <[email protected]>
Remove live ranges from Document.h, AlternativeTextController.h, DictionaryLookup.h, and WebPage.h
Modified: trunk/Source/WebKit/UIProcess/WebPageProxy.cpp (264320 => 264321)
--- trunk/Source/WebKit/UIProcess/WebPageProxy.cpp 2020-07-13 22:12:59 UTC (rev 264320)
+++ trunk/Source/WebKit/UIProcess/WebPageProxy.cpp 2020-07-13 22:31:53 UTC (rev 264321)
@@ -3209,6 +3209,8 @@
void WebPageProxy::receivedNavigationPolicyDecision(PolicyAction policyAction, API::Navigation* navigation, ProcessSwapRequestedByClient processSwapRequestedByClient, WebFrameProxy& frame, RefPtr<API::WebsitePolicies>&& policies, Ref<PolicyDecisionSender>&& sender)
{
+ RELEASE_LOG_ERROR_IF_ALLOWED(Loading, "receivedNavigationPolicyDecision: frameID: %llu, navigationID: %llu, policyAction: %u", frame.frameID().toUInt64(), navigation ? navigation->navigationID() : 0, (unsigned)policyAction);
+
Ref<WebsiteDataStore> websiteDataStore = m_websiteDataStore.copyRef();
if (policies) {
if (policies->websiteDataStore() && policies->websiteDataStore() != websiteDataStore.ptr()) {
@@ -5097,6 +5099,8 @@
NavigationActionData&& navigationActionData, FrameInfoData&& originatingFrameInfoData, Optional<WebPageProxyIdentifier> originatingPageID, const WebCore::ResourceRequest& originalRequest, WebCore::ResourceRequest&& request,
IPC::FormDataReference&& requestBody, WebCore::ResourceResponse&& redirectResponse, const UserData& userData, Ref<PolicyDecisionSender>&& sender)
{
+ RELEASE_LOG_ERROR_IF_ALLOWED(Loading, "decidePolicyForNavigationAction: frameID: %llu, navigationID: %llu", frame.frameID().toUInt64(), navigationID);
+
LOG(Loading, "WebPageProxy::decidePolicyForNavigationAction - Original URL %s, current target URL %s", originalRequest.url().string().utf8().data(), request.url().string().utf8().data());
PageClientProtector protector(pageClient());
@@ -5171,6 +5175,7 @@
#endif
auto listener = makeRef(frame.setUpPolicyListenerProxy([this, protectedThis = makeRef(*this), frame = makeRef(frame), sender = WTFMove(sender), navigation, frameInfo, userDataObject = process->transformHandlesToObjects(userData.object()).get()] (PolicyAction policyAction, API::WebsitePolicies* policies, ProcessSwapRequestedByClient processSwapRequestedByClient, RefPtr<SafeBrowsingWarning>&& safeBrowsingWarning, Optional<NavigatingToAppBoundDomain> isAppBoundDomain) mutable {
+ RELEASE_LOG_ERROR_IF_ALLOWED(Loading, "decidePolicyForNavigationAction: listener called: frameID: %llu, navigationID: %llu, policyAction: %u, safeBrowsingWarning: %d, isAppBoundDomain: %d", frame->frameID().toUInt64(), navigation ? navigation->navigationID() : 0, (unsigned)policyAction, !!safeBrowsingWarning, !!isAppBoundDomain);
auto completionHandler = [this, protectedThis, frame, sender = WTFMove(sender), navigation, processSwapRequestedByClient, policies = makeRefPtr(policies)] (PolicyAction policyAction) mutable {
if (frame->isMainFrame()) {