Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: fcded16b06bb20e17608486228e58ed918633a9b
https://github.com/WebKit/WebKit/commit/fcded16b06bb20e17608486228e58ed918633a9b
Author: Cole Carley <[email protected]>
Date: 2026-03-26 (Thu, 26 Mar 2026)
Changed paths:
M Source/WebKit/WebProcess/WebPage/FindController.cpp
M Tools/TestWebKitAPI/Tests/WebKitCocoa/WKWebViewFindString.mm
Log Message:
-----------
Find in page match is updated incorrectly
https://bugs.webkit.org/show_bug.cgi?id=310679
rdar://173280425
Reviewed by Megan Gardner.
The match index was being updated incorrectly after changing the type
from an int to an optional unsigned. I fix the logic and consolidated
it to one function.
* Source/WebKit/WebProcess/WebPage/FindController.cpp:
(WebKit::FindController::updateMatchIndex):
(WebKit::FindController::findString):
Added some tests to exercise this change.
* Tools/TestWebKitAPI/Tests/WebKitCocoa/WKWebViewFindString.mm:
(TestWebKitAPI::TEST(WKWebViewFindString,
MatchIndexDoesNotUpdateWithoutDetermineMatchIndexOption)):
(TestWebKitAPI::TEST(WKWebViewFindString,
MatchIndexIsCorrectNavigatingWrapAround)):
(TestWebKitAPI::TEST(WKWebViewFindString,
MatchIndexIsCorrectNavigatingWrapAroundBackwards)):
Canonical link: https://commits.webkit.org/310022@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications