Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 23b0720b409a8aa5c963c9ff6fb47626619bd648
      
https://github.com/WebKit/WebKit/commit/23b0720b409a8aa5c963c9ff6fb47626619bd648
  Author: Geoffrey Garen <[email protected]>
  Date:   2026-10-14 (Wed, 14 Oct 2026)

  Changed paths:
    M Source/WebKit/WebProcess/WebPage/WebPage.cpp

  Log Message:
  -----------
  [Safer CPP] Move text recognition completion handlers out before calling them
https://bugs.webkit.org/show_bug.cgi?id=327581
rdar://190050490

Reviewed by Wenson Hsieh and Ryosuke Niwa.

Previous behavior invoked completion handlers by iterating a Vector in
place. Our new Borrow<T> rules forbid that approach.

New behavior: Move out all handlers we're going to call before we call the
first one.

Out of an abundance of caution, I'm landing this change separately because
there's a small chance it will change behavior if previous code re-entrantly
registered duplicate completion handlers without crashing in practice.

* Source/WebKit/WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::requestTextRecognition):

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



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to