Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 7429b2822b74a3a85823d06460044593f1514fe1
      
https://github.com/WebKit/WebKit/commit/7429b2822b74a3a85823d06460044593f1514fe1
  Author: Ahmad Saleem <[email protected]>
  Date:   2026-06-29 (Mon, 29 Jun 2026)

  Changed paths:
    M Source/WebCore/page/Quirks.cpp

  Log Message:
  -----------
  Avoid constructing the frame RegistrableDomain twice in 
Quirks::triggerOptionalStorageAccessIframeQuirk
https://bugs.webkit.org/show_bug.cgi?id=318102
rdar://180895252

Reviewed by Chris Dumez.

triggerOptionalStorageAccessIframeQuirk() built RegistrableDomain { frameURL }
twice on the path where the quirk fires: once for the
subFrameDomainsForStorageAccessQuirk().contains() test and again as the
argument to requestStorageAccessForNonDocumentQuirk(). Constructing a
RegistrableDomain performs a public-suffix-list (PSL) lookup, so this did
the work twice for the same URL.

Hoist a single RegistrableDomain local, reuse it for contains(), and
WTF::move() it into the call (also saving a copy). The surrounding block
already constructs RegistrableDomain { document->url() } unconditionally for
the isProbablyGoogleCCTLD check, so this does not introduce PSL work on an
otherwise-cold path. No behavior change.

* Source/WebCore/page/Quirks.cpp:

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



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

Reply via email to