[webkit-changes] [WebKit/WebKit] 312ff4: Fix a rare crash under data detector highlight pai...

Wenson Hsieh noreply at github.com
Mon Jan 30 17:41:25 PST 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 312ff43f570cd2057a1508cad8c8b6be6bee8b3a
      https://github.com/WebKit/WebKit/commit/312ff43f570cd2057a1508cad8c8b6be6bee8b3a
  Author: Wenson Hsieh <wenson_hsieh at apple.com>
  Date:   2023-01-30 (Mon, 30 Jan 2023)

  Changed paths:
    M Source/WebCore/platform/mac/DataDetectorHighlight.mm

  Log Message:
  -----------
  Fix a rare crash under data detector highlight painting logic
https://bugs.webkit.org/show_bug.cgi?id=251384
rdar://104723803

Reviewed by Megan Gardner.

Add a null check for the `DDHighlightRef` before attempting to ask for `DDHighlightGetBoundingRect`.
It's not clear how to trigger this crash, so this patch only makes this painting codepath robust
against `m_highlight` being `nil`.

* Source/WebCore/platform/mac/DataDetectorHighlight.mm:
(WebCore::DataDetectorHighlight::paintContents):

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




More information about the webkit-changes mailing list