Skip to content

Commit

Permalink
Cherry-pick 2aaac53. rdar://126706870
Browse files Browse the repository at this point in the history
    Add page null check under [WKWebProcessPlugInFrame _browserContextController]
    https://bugs.webkit.org/show_bug.cgi?id=271174
    rdar://122276358

    Reviewed by Sihui Liu.

    Add page null check under [WKWebProcessPlugInFrame _browserContextController] to address
    some crashes in the wild.

    * Source/WebKit/WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInFrame.mm:
    (-[WKWebProcessPlugInFrame _browserContextController]):

    Canonical link: https://commits.webkit.org/276318@main
  • Loading branch information
cdumez authored and Mohsin Qureshi committed Apr 18, 2024
1 parent c60dc8b commit bcea360
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,8 @@ - (JSValue *)jsRangeForRangeHandle:(WKWebProcessPlugInRangeHandle *)rangeHandle

- (WKWebProcessPlugInBrowserContextController *)_browserContextController
{
if (!_frame->page())
return nil;
return WebKit::wrapper(*_frame->page());
}

Expand Down

0 comments on commit bcea360

Please sign in to comment.