[webkit-changes] [WebKit/WebKit] 53f7b4: Avoid an occasional null deref under Quirks::advan...

Wenson Hsieh noreply at github.com
Mon Oct 30 17:02:19 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 53f7b4f3ed1cdc390e16671f5c6e8213ad9c6136
      https://github.com/WebKit/WebKit/commit/53f7b4f3ed1cdc390e16671f5c6e8213ad9c6136
  Author: Wenson Hsieh <wenson_hsieh at apple.com>
  Date:   2023-10-30 (Mon, 30 Oct 2023)

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

  Log Message:
  -----------
  Avoid an occasional null deref under Quirks::advancedPrivacyProtectionSubstituteDataURLForScriptWithFeatures
https://bugs.webkit.org/show_bug.cgi?id=263914
rdar://117671779

Reviewed by Aditya Keerthi.

Add a null check and bail in `advancedPrivacyProtectionSubstituteDataURLForScriptWithFeatures`, in
the case where the `CodeBlock`'s owner executable is null. Currently, we call `source()` to grab
the corresponding `JSC::SourceCode`, which assumes that `m_ownerExecutable` exists (which isn't
always the case).

* Source/WebCore/page/Quirks.cpp:
(WebCore::Quirks::advancedPrivacyProtectionSubstituteDataURLForScriptWithFeatures const):

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




More information about the webkit-changes mailing list