Title: [241151] branches/safari-607-branch/Source/WebKit
Revision
241151
Author
[email protected]
Date
2019-02-07 15:36:15 -0800 (Thu, 07 Feb 2019)

Log Message

Cherry-pick r239697. rdar://problem/47776479

    Web Inspector: Remote inspector can crash if attempting to navigate inspector page
    https://bugs.webkit.org/show_bug.cgi?id=193204
    <rdar://problem/45550428>

    Patch by Joseph Pecoraro <[email protected]> on 2019-01-07
    Reviewed by Devin Rousso.

    * UIProcess/mac/RemoteWebInspectorProxyMac.mm:
    (WebKit::RemoteWebInspectorProxy::platformCreateFrontendPageAndWindow):
    * UIProcess/mac/WKInspectorViewController.mm:
    (-[WKInspectorViewController webView:decidePolicyForNavigationAction:decisionHandler:]):

    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@239697 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Modified Paths

Diff

Modified: branches/safari-607-branch/Source/WebKit/ChangeLog (241150 => 241151)


--- branches/safari-607-branch/Source/WebKit/ChangeLog	2019-02-07 23:34:26 UTC (rev 241150)
+++ branches/safari-607-branch/Source/WebKit/ChangeLog	2019-02-07 23:36:15 UTC (rev 241151)
@@ -1,3 +1,34 @@
+2019-02-07  Alan Coon  <[email protected]>
+
+        Cherry-pick r239697. rdar://problem/47776479
+
+    Web Inspector: Remote inspector can crash if attempting to navigate inspector page
+    https://bugs.webkit.org/show_bug.cgi?id=193204
+    <rdar://problem/45550428>
+    
+    Patch by Joseph Pecoraro <[email protected]> on 2019-01-07
+    Reviewed by Devin Rousso.
+    
+    * UIProcess/mac/RemoteWebInspectorProxyMac.mm:
+    (WebKit::RemoteWebInspectorProxy::platformCreateFrontendPageAndWindow):
+    * UIProcess/mac/WKInspectorViewController.mm:
+    (-[WKInspectorViewController webView:decidePolicyForNavigationAction:decisionHandler:]):
+    
+    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@239697 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+    2019-01-07  Joseph Pecoraro  <[email protected]>
+
+            Web Inspector: Remote inspector can crash if attempting to navigate inspector page
+            https://bugs.webkit.org/show_bug.cgi?id=193204
+            <rdar://problem/45550428>
+
+            Reviewed by Devin Rousso.
+
+            * UIProcess/mac/RemoteWebInspectorProxyMac.mm:
+            (WebKit::RemoteWebInspectorProxy::platformCreateFrontendPageAndWindow):
+            * UIProcess/mac/WKInspectorViewController.mm:
+            (-[WKInspectorViewController webView:decidePolicyForNavigationAction:decisionHandler:]):
+
 2019-02-06  Alan Coon  <[email protected]>
 
         Apply patch. rdar://problem/47822019

Modified: branches/safari-607-branch/Source/WebKit/UIProcess/mac/RemoteWebInspectorProxyMac.mm (241150 => 241151)


--- branches/safari-607-branch/Source/WebKit/UIProcess/mac/RemoteWebInspectorProxyMac.mm	2019-02-07 23:34:26 UTC (rev 241150)
+++ branches/safari-607-branch/Source/WebKit/UIProcess/mac/RemoteWebInspectorProxyMac.mm	2019-02-07 23:36:15 UTC (rev 241151)
@@ -85,7 +85,7 @@
 {
     m_objCAdapter = adoptNS([[WKRemoteWebInspectorProxyObjCAdapter alloc] initWithRemoteWebInspectorProxy:this]);
 
-    m_inspectorView = adoptNS([[WKInspectorViewController alloc] initWithInspectedPage:nil]);
+    m_inspectorView = adoptNS([[WKInspectorViewController alloc] initWithInspectedPage:nullptr]);
     [m_inspectorView.get() setDelegate:m_objCAdapter.get()];
 
     m_window = WebInspectorProxy::createFrontendWindow(NSZeroRect);

Modified: branches/safari-607-branch/Source/WebKit/UIProcess/mac/WKInspectorViewController.mm (241150 => 241151)


--- branches/safari-607-branch/Source/WebKit/UIProcess/mac/WKInspectorViewController.mm	2019-02-07 23:34:26 UTC (rev 241150)
+++ branches/safari-607-branch/Source/WebKit/UIProcess/mac/WKInspectorViewController.mm	2019-02-07 23:36:15 UTC (rev 241151)
@@ -226,7 +226,8 @@
     decisionHandler(WKNavigationActionPolicyCancel);
     
     // And instead load it in the inspected page.
-    _inspectedPage->loadRequest(navigationAction.request);
+    if (_inspectedPage)
+        _inspectedPage->loadRequest(navigationAction.request);
 }
 
 // MARK: WKInspectorWKWebViewDelegate methods
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to