[webkit-changes] [WebKit/WebKit] 7b3382: REGRESSION (267082 at main): Safari crashes when clic...

Wenson Hsieh noreply at github.com
Mon Aug 21 15:47:22 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 7b338282b8963d14033b581af81113050f48b5cc
      https://github.com/WebKit/WebKit/commit/7b338282b8963d14033b581af81113050f48b5cc
  Author: Wenson Hsieh <wenson_hsieh at apple.com>
  Date:   2023-08-21 (Mon, 21 Aug 2023)

  Changed paths:
    M Source/WebKit/UIProcess/mac/WKImmediateActionController.h
    M Source/WebKit/UIProcess/mac/WKImmediateActionController.mm
    M Source/WebKit/UIProcess/mac/WebViewImpl.h

  Log Message:
  -----------
  REGRESSION (267082 at main): Safari crashes when clicking text inside form controls
https://bugs.webkit.org/show_bug.cgi?id=260470
rdar://114196908

Reviewed by Ryosuke Niwa and Richard Robinson.

Don't use `RetainPtr` to protect `WebKit::WebViewImpl`; instead, just turn the `WebViewImpl` pointer
into a `CheckedPtr` to verify that the `WebViewImpl` (like `WebPageProxy`) always outlives this
object. We also wrap both `_page` and `_viewImpl` with a `CheckedPtr` on the stack.

Test:   ImmediateActionTests.ImmediateActionOverText
        ImmediateActionTests.ImmediateActionOverImageOverlay

* Source/WebKit/UIProcess/mac/WKImmediateActionController.h:
* Source/WebKit/UIProcess/mac/WKImmediateActionController.mm:
(-[WKImmediateActionController _clearImmediateActionState]):
(-[WKImmediateActionController dismissContentRelativeChildWindows]):
(-[WKImmediateActionController immediateActionRecognizerWillPrepare:]):
(-[WKImmediateActionController immediateActionRecognizerWillBeginAnimation:]):
(-[WKImmediateActionController immediateActionRecognizerDidUpdateAnimation:]):
(-[WKImmediateActionController immediateActionRecognizerDidCancelAnimation:]):
(-[WKImmediateActionController immediateActionRecognizerDidCompleteAnimation:]):
(-[WKImmediateActionController _webHitTestResult]):
(-[WKImmediateActionController _defaultAnimationController]):
(-[WKImmediateActionController _updateImmediateActionItem]):
(-[WKImmediateActionController _animationControllerForText]):
* Source/WebKit/UIProcess/mac/WebViewImpl.h:

Canonical link: https://commits.webkit.org/267108@main




More information about the webkit-changes mailing list