⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Timeline



Mar 4, 2021:

11:05 PM Changeset in webkit [273950] by commit-queue@webkit.org
  • 4 edits in trunk/Source

Add internal preference to disable HTTPS upgrade
https://bugs.webkit.org/show_bug.cgi?id=222778

Patch by Alex Christensen <achristensen@webkit.org> on 2021-03-04
Reviewed by Simon Fraser.

Source/WebKit:

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::creationParameters):

Source/WTF:

This is needed for an internal performance benchmark, which serves canned content from a local http server
pretending to be from different domains that are in our internal HTTPS upgrade list because the real server
supports HTTPS. That internal benchmark should eventually change, but that's not going to happen this year.
This is also likely going to be useful for QA purposes to be able to easily tell on an internal build
whether HTTPS upgrade is breaking something.

  • Scripts/Preferences/WebPreferencesInternal.yaml:
9:47 PM Changeset in webkit [273949] by achristensen@apple.com
  • 3 edits in trunk/Source/WebKit

Fix clean build after r273946
https://bugs.webkit.org/show_bug.cgi?id=222706

  • DerivedSources-output.xcfilelist:
  • WebKit.xcodeproj/project.pbxproj:
9:46 PM Changeset in webkit [273948] by Russell Epstein
  • 3 edits in branches/safari-612.1.5-branch/Source/WebKit

Cherry-pick r273485. rdar://problem/75075088

Temporarily stop enforcing notification filtering
https://bugs.webkit.org/show_bug.cgi?id=222386
<rdar://problem/73987767>

Reviewed by Brent Fulgham.

Temporarily stop enforcing notification filtering on macOS and iOS.

  • Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:
  • WebProcess/com.apple.WebProcess.sb.in:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@273485 268f45cc-cd09-0410-ab3c-d52691b4dbfc

8:48 PM Changeset in webkit [273947] by Aditya Keerthi
  • 7 edits
    1 move in trunk/Source/WebCore

[iOS] Add legacy prefix to the form controls UA stylesheet
https://bugs.webkit.org/show_bug.cgi?id=222741
<rdar://problem/75039764>

Reviewed by Ryosuke Niwa.

Followup to r273839. Rename the iOS form controls UA stylesheet to
indicate it contains outdated styles.

  • DerivedSources-input.xcfilelist:
  • DerivedSources.make:
  • WebCore.xcodeproj/project.pbxproj:
  • css/legacyFormControlsIOS.css: Renamed from Source/WebCore/css/formControlsIOS.css.

Removed redundant comment after the rename.

  • style/InspectorCSSOMWrappers.cpp:

(WebCore::Style::InspectorCSSOMWrappers::collectDocumentWrappers):

  • style/UserAgentStyle.cpp:

(WebCore::Style::UserAgentStyle::ensureDefaultStyleSheetsForElement):

  • style/UserAgentStyle.h:
8:41 PM Changeset in webkit [273946] by achristensen@apple.com
  • 2 edits
    2 deletes in trunk/Source/WebKit

Remove the HTTPSUpgradeEnabled experimental feature
https://bugs.webkit.org/show_bug.cgi?id=222706

Reviewed by Simon Fraser.

  • DerivedSources.make:
  • Scripts/generate-https-upgrade-database.sh: Removed.
  • Shared/HTTPSUpgrade/HTTPSUpgradeList.txt: Removed.
8:36 PM Changeset in webkit [273945] by Russell Epstein
  • 1 copy in tags/Safari-612.1.5.2.2

Tag Safari-612.1.5.2.2.

8:36 PM Changeset in webkit [273944] by Chris Dumez
  • 2 edits in trunk/Source/WebCore

Make RegistrableDomain() private constructor take the String as an rvalue reference
https://bugs.webkit.org/show_bug.cgi?id=222767

Reviewed by Alex Christensen.

Make RegistrableDomain() private constructor take the String as an rvalue reference.
Most call sites have an rvalue reference and it reduces ref counting churn this way.

  • platform/RegistrableDomain.h:

(WebCore::RegistrableDomain::uncheckedCreateFromRegistrableDomainString):
(WebCore::RegistrableDomain::uncheckedCreateFromHost):
(WebCore::RegistrableDomain::RegistrableDomain):

8:36 PM Changeset in webkit [273943] by Russell Epstein
  • 3 edits in branches/safari-612.1.5.2-branch/Source/WebKit

Cherry-pick r273485. rdar://problem/75075050

Temporarily stop enforcing notification filtering
https://bugs.webkit.org/show_bug.cgi?id=222386
<rdar://problem/73987767>

Reviewed by Brent Fulgham.

Temporarily stop enforcing notification filtering on macOS and iOS.

  • Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:
  • WebProcess/com.apple.WebProcess.sb.in:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@273485 268f45cc-cd09-0410-ab3c-d52691b4dbfc

8:35 PM Changeset in webkit [273942] by Russell Epstein
  • 8 edits in branches/safari-612.1.5.2-branch/Source

Versioning.

WebKit-7612.1.5.2.2

8:33 PM Changeset in webkit [273941] by Chris Dumez
  • 5 edits in trunk/Source/WebKit

NetworkProcessProxy::deleteWebsiteDataInUIProcessForRegistrableDomains() can take domains as an rvalue reference
https://bugs.webkit.org/show_bug.cgi?id=222768

Reviewed by Geoffrey Garen.

  • UIProcess/Network/NetworkProcessProxy.cpp:

(WebKit::NetworkProcessProxy::deleteWebsiteDataInUIProcessForRegistrableDomains):

  • UIProcess/Network/NetworkProcessProxy.h:
  • UIProcess/WebsiteData/WebsiteDataStore.cpp:

(WebKit::WebsiteDataStore::fetchDataForRegistrableDomains):

  • UIProcess/WebsiteData/WebsiteDataStore.h:
8:17 PM Changeset in webkit [273940] by achristensen@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

[Cocoa] REGRESSION(r272752): fix some internal builds that use WTFString::WTFString(NSString *)
https://bugs.webkit.org/show_bug.cgi?id=222610

Reviewed by Chris Dumez.

  • inspector/scripts/codegen/objc_generator.py:

(ObjCGenerator.objc_protocol_import_expression_for_member):
(ObjCGenerator.objc_protocol_import_expression_for_parameter):
(ObjCGenerator.protocol_to_objc_expression_for_member):
(ObjCGenerator.payload_to_objc_expression_for_member):

7:21 PM WebKitGTK/2.32.x edited by clopez@igalia.com
(diff)
6:57 PM Changeset in webkit [273939] by Devin Rousso
  • 4 edits in trunk/Source

[Payment Request] remove some unnecessary WebKitAdditions hooks
https://bugs.webkit.org/show_bug.cgi?id=222765
<rdar://problem/75060894>

Reviewed by Andy Estes.

Source/WebCore:

  • Modules/applepay/ApplePaySession.cpp:

Source/WebKit:

  • Shared/ApplePay/cocoa/WebPaymentCoordinatorProxyCocoa.mm:
5:50 PM Changeset in webkit [273938] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

Deploy Ref<T> in SVGUseElement.cpp
https://bugs.webkit.org/show_bug.cgi?id=222637

Patch by Julian Gonzalez <julian_a_gonzalez@apple.com> on 2021-03-04
Reviewed by Ryosuke Niwa.

Remove usage of raw pointers in a few functions here
that showed issues in 222397.

Thanks to Darin Adler for the initial version of this patch
and Ryosuke Niwa for refinements.

  • svg/SVGUseElement.cpp:

(WebCore::disassociateAndRemoveClones):
(WebCore::removeDisallowedElementsFromSubtree):
(WebCore::removeSymbolElementsFromSubtree):

5:45 PM Changeset in webkit [273937] by Russell Epstein
  • 1 copy in tags/Safari-611.1.21.0.4

Tag Safari-611.1.21.0.4.

5:44 PM Changeset in webkit [273936] by Russell Epstein
  • 1 copy in tags/Safari-611.1.21.1.5

Tag Safari-611.1.21.1.5.

5:28 PM Changeset in webkit [273935] by rniwa@webkit.org
  • 11 edits in trunk/Source/WebCore

"precustomized" state of custom elements can become HTMLUnknownElement
https://bugs.webkit.org/show_bug.cgi?id=221652

Reviewed by Darin Adler.

The bug was caused by createJSHTMLWrapper in JSHTMLElementWrapperFactory.cpp relying on
!isCustomElementUpgradeCandidate() to create HTMLUnknownElement as JS wrapper of the element.

This is problematic after r266269 since that change re-purposes CustomElementState::Failed
on a custom element as "precustomized" state instead of introducing another enum value in
CustomElementState as RareDataBitFields has no more bits available.

This patch fixes the problem by introducing a new NodeFlag::IsUnknownElement and using that
to check whether JSHTMLUnknownElement should be created for a given element or not. Note that
HTMLElement had a virtual function, isHTMLUnknownElement, to check this condition but invoking
a virtual function proved to incur too much runtime cost.

  • dom/Node.h:

(WebCore::Node::isUnknownElement const): Added.
(WebCore::Node::isHTMLUnknownElement const): Added.
(WebCore::Node::isSVGUnknownElement const): Added.
(WebCore::Node::isMathMLUnknownElement const): Added.
(WebCore::Node::NodeFlag): Added NodeFlag::IsUnknownElement.

  • dom/make_names.pl:

(printWrapperFactoryCppFile): Treat the element as HTMLUnknownElement only if isUnknownElement
returns true instead of isCustomElementUpgradeCandidate returning false.

  • html/HTMLElement.h:

(WebCore::HTMLElement::isHTMLUnknownElement const): Deleted.

  • html/HTMLUnknownElement.h:
  • mathml/MathMLElement.cpp:

(WebCore::MathMLElement::MathMLElement): Added ConstructionType as an argument.

  • mathml/MathMLElement.h:
  • mathml/MathMLUnknownElement.h:

(WebCore::MathMLUnknownElement::MathMLUnknownElement): Set NodeFlag::IsUnknownElement.

  • svg/SVGElement.cpp:

(WebCore::SVGElement::SVGElement): Added ConstructionType as an argument.

  • svg/SVGElement.h:
  • svg/SVGUnknownElement.h:

(WebCore::SVGUnknownElement::SVGUnknownElement): Set NodeFlag::IsUnknownElement.

5:18 PM Changeset in webkit [273934] by commit-queue@webkit.org
  • 6 edits in trunk/Tools

Undeprecate many more webkit-patch commands
https://bugs.webkit.org/show_bug.cgi?id=222745

Patch by Sam Sneddon <Sam Sneddon> on 2021-03-04
Reviewed by Jonathan Bedard.

  • Scripts/webkitpy/tool/commands/download.py:

(ChangeStyleLocal):

  • Scripts/webkitpy/tool/commands/queries.py:

(SuggestReviewers):

  • Scripts/webkitpy/tool/commands/setupgitclone.py:

(SetupGitClone):

  • Scripts/webkitpy/tool/commands/suggestnominations.py:

(SuggestNominations):

  • Scripts/webkitpy/tool/commands/upload.py:

(Post):
(Prepare):
(MarkBugFixed):

4:45 PM Changeset in webkit [273933] by Peng Liu
  • 2 edits in trunk/LayoutTests

[GPUP] Some tests in imported/w3c/web-platform-tests/html/semantics/embedded-content/media-elements fail when media in GPU Process is enabled
https://bugs.webkit.org/show_bug.cgi?id=221697

Unreviewed test gardening.

Remove the tests which are consistently passing on bots from the test expectations.

  • platform/wk2/TestExpectations:
4:43 PM Changeset in webkit [273932] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Unreivewed test gardening, remove failure expectation for some tests that are consistently passing.

  • platform/ios-wk2/TestExpectations:
4:18 PM Changeset in webkit [273931] by sbarati@apple.com
  • 17 edits
    1 add in trunk

Don't trust parsing information to tell us if we've emitted op_call_eval
https://bugs.webkit.org/show_bug.cgi?id=222694
rdar://74778016

Reviewed by Yusuke Suzuki.

JSTests:

  • stress/eval-liveness-should-not-come-from-parser.js: Added.

(foo):

Source/JavaScriptCore:

In the DFG, op_call_eval can't be inlined. Not inlining is required for how
eval is currently implemented in the DFG. For CodeBlocks with eval in them,
the scope register is also alive everywhere.

When doing spread of arguments in eval, we end up emitting a call varargs
instead of a direct eval. This seems like a spec bug:
https://bugs.webkit.org/show_bug.cgi?id=222671

However, this leads to something that had eval textually in it leading to
us reporting the scope register is always alive, even if op_call_eval isn't
in the bytecode stream. This leads to a validation error, since the DFG
isn't actually keeping this scope register alive everywhere, because
op_call_eval isn't in the bytecode stream.

This patch fixes this by having a bit indicating if op_call_eval is in
the bytecode stream or not.

  • bytecode/BytecodeUseDef.h:

(JSC::computeUsesForBytecodeIndex):

  • bytecode/CodeBlock.h:

(JSC::CodeBlock::usesCallEval const):
(JSC::CodeBlock::usesEval const): Deleted.

  • bytecode/ExecutableInfo.h:

(JSC::ExecutableInfo::ExecutableInfo):
(JSC::ExecutableInfo::usesEval const): Deleted.

  • bytecode/UnlinkedCodeBlock.cpp:

(JSC::UnlinkedCodeBlock::UnlinkedCodeBlock):

  • bytecode/UnlinkedCodeBlock.h:

(JSC::UnlinkedCodeBlock::usesCallEval const):
(JSC::UnlinkedCodeBlock::setUsesCallEval):
(JSC::UnlinkedCodeBlock::usesEval const): Deleted.

  • bytecode/UnlinkedCodeBlockGenerator.h:

(JSC::UnlinkedCodeBlockGenerator::usesCallEval const):
(JSC::UnlinkedCodeBlockGenerator::setUsesCallEval):
(JSC::UnlinkedCodeBlockGenerator::usesEval const): Deleted.

  • bytecode/UnlinkedFunctionExecutable.cpp:

(JSC::generateUnlinkedFunctionCodeBlock):

  • bytecompiler/BytecodeGenerator.cpp:

(JSC::BytecodeGenerator::BytecodeGenerator):
(JSC::BytecodeGenerator::emitCall):
(JSC::BytecodeGenerator::isThisUsedInInnerArrowFunction):
(JSC::BytecodeGenerator::isNewTargetUsedInInnerArrowFunction):
(JSC::BytecodeGenerator::isSuperUsedInInnerArrowFunction):
(JSC::BytecodeGenerator::isSuperCallUsedInInnerArrowFunction):

  • dfg/DFGGraph.h:
  • runtime/CachedTypes.cpp:

(JSC::CachedCodeBlock::usesCallEval const):
(JSC::UnlinkedCodeBlock::UnlinkedCodeBlock):
(JSC::CachedCodeBlock<CodeBlockType>::encode):
(JSC::CachedCodeBlock::usesEval const): Deleted.

  • runtime/CodeCache.cpp:

(JSC::generateUnlinkedCodeBlockImpl):

  • runtime/EvalExecutable.h:

(JSC::EvalExecutable::executableInfo const): Deleted.

  • runtime/ModuleProgramExecutable.h:
  • runtime/ProgramExecutable.h:
  • runtime/ScriptExecutable.h:

(JSC::ScriptExecutable::usesEval const): Deleted.

4:14 PM Changeset in webkit [273930] by aakash_jain@apple.com
  • 2 edits in trunk/Tools

Reduce unnecessary logging in ews-app
https://bugs.webkit.org/show_bug.cgi?id=222764

Reviewed by Jonathan Bedard.

  • CISupport/ews-app/ews/views/retrypatch.py:

(RetryPatch.post):

4:12 PM Changeset in webkit [273929] by commit-queue@webkit.org
  • 10 edits in trunk/Source/WebKit

Validate documentState of FrameState when setting and getting it
https://bugs.webkit.org/show_bug.cgi?id=222587

Patch by Sihui Liu <sihui_liu@appe.com> on 2021-03-04
Reviewed by Geoffrey Garen.

In rdar://48634553, strings of documentState can be invalid when they are encoded in encodeFrameStateNode
in UI process. To get a better idea of when the strings become invalid, add checks for documentState when
getting and setting it.

No test as no behavior change.

  • Shared/SessionState.cpp:

(WebKit::FrameState::encode const):
(WebKit::FrameState::decode):
(WebKit::FrameState::validateDocumentState const):
(WebKit::FrameState::setDocumentState):

  • Shared/SessionState.h:

(WebKit::FrameState::FrameState):
(WebKit::FrameState::~FrameState):
(WebKit::FrameState::documentState const):

  • Shared/WebBackForwardListItem.cpp:

(WebKit::WebBackForwardListItem::create):
(WebKit::WebBackForwardListItem::~WebBackForwardListItem):

  • UIProcess/API/glib/WebKitWebViewSessionState.cpp:

(encodeFrameState):
(decodeFrameState):

  • UIProcess/Cocoa/SessionStateCoding.h:
  • UIProcess/LegacySessionStateCoding.h:
  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::sessionState const):

  • UIProcess/mac/LegacySessionStateCoding.cpp:

(WebKit::encodeFrameStateNode):
(WebKit::decodeBackForwardTreeNode):

  • WebProcess/WebCoreSupport/SessionStateConversion.cpp:

(WebKit::toFrameState):
(WebKit::applyFrameState):

3:58 PM Changeset in webkit [273928] by don.olmstead@sony.com
  • 6 edits in trunk/Source/WebCore

Non-unified build fixes, early March 2021 edition
https://bugs.webkit.org/show_bug.cgi?id=222755

Unreviewed non-unified build fixes.

  • dom/EventContext.cpp:
  • html/canvas/ImageBitmapRenderingContext.cpp:
  • inspector/agents/worker/WorkerNetworkAgent.cpp:
  • page/scrolling/nicosia/ScrollingTreeScrollingNodeDelegateNicosia.cpp:
  • rendering/RenderModel.cpp:
3:46 PM Changeset in webkit [273927] by jonlee@apple.com
  • 2 edits in trunk/LayoutTests

[GPUP] Test platform/mac/media/encrypted-media/fps-encrypted-event.html times out when media in GPU Process is enabled
https://bugs.webkit.org/show_bug.cgi?id=221847

Reviewed by Simon Fraser.

  • platform/mac-wk2/TestExpectations: The test no longer times out. Remove expectation.
3:37 PM Changeset in webkit [273926] by Matt Lewis
  • 3 edits in trunk/Tools

Add Apple Silicon Devices to Big Sur builders and testers.
https://bugs.webkit.org/show_bug.cgi?id=222616

Reviewed by Aakash Jain.

  • CISupport/build-webkit-org/config.json:
  • CISupport/build-webkit-org/public_html/dashboard/Scripts/WebKitBuildbot.js:

(WebKitBuildbot):

3:30 PM Changeset in webkit [273925] by Russell Epstein
  • 16 edits
    1 copy in branches/safari-612.1.5-branch

Cherry-pick r273784. rdar://problem/75059445

REGRESSION(r270691): It's impossible to use MobileAsset fonts on macOS
https://bugs.webkit.org/show_bug.cgi?id=222582
<rdar://problem/74877450>

Reviewed by Per Arne Vollan.

Source/WebKit:

Simply apply the iOS codepath to macOS.

There is also an additional change here to the Mac sandbox.
On Big Sur and earlier, before this patch, com.apple.mobileassetd was allowed,
and com.apple.mobileassetd.v2 was disallowed. After this patch, they both are
allowed, but only with the com.apple.webkit.extension.mach extension.
On other OSes, before this patch, nothing was allowed, whereas after this patch,
only com.apple.mobileassetd.v2 is allowed with the com.apple.webkit.extension.mach
extension.

Test: WebKit.MobileAssetSandboxCheck

  • UIProcess/API/Cocoa/WKWebView.mm: (-[WKWebView _grantAccessToAssetServices]): (-[WKWebView _revokeAccessToAssetServices]):
  • UIProcess/API/Cocoa/WKWebViewPrivate.h:
  • UIProcess/API/ios/WKWebViewIOS.mm: (-[WKWebView _grantAccessToAssetServices]): Deleted. (-[WKWebView _revokeAccessToAssetServices]): Deleted.
  • UIProcess/Cocoa/WebPageProxyCocoa.mm: (WebKit::WebPageProxy::grantAccessToAssetServices): (WebKit::WebPageProxy::revokeAccessToAssetServices):
  • UIProcess/WebPageProxy.h:
  • UIProcess/ios/WebPageProxyIOS.mm: (WebKit::WebPageProxy::grantAccessToAssetServices): Deleted. (WebKit::WebPageProxy::revokeAccessToAssetServices): Deleted.
  • WebProcess/WebProcess.h:
  • WebProcess/WebProcess.messages.in:
  • WebProcess/cocoa/WebProcessCocoa.mm: (WebKit::WebProcess::revokeAccessToAssetServices):
  • WebProcess/com.apple.WebProcess.sb.in:
  • WebProcess/glib/WebProcessGLib.cpp: (WebKit::WebProcess::grantAccessToAssetServices): (WebKit::WebProcess::revokeAccessToAssetServices):
  • WebProcess/playstation/WebProcessPlayStation.cpp: (WebKit::WebProcess::grantAccessToAssetServices): (WebKit::WebProcess::revokeAccessToAssetServices):
  • WebProcess/win/WebProcessWin.cpp: (WebKit::WebProcess::grantAccessToAssetServices): (WebKit::WebProcess::revokeAccessToAssetServices):

Tools:

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WebKit/MobileAssetSandboxCheck.mm: Copied from Source/WebKit/WebProcess/win/WebProcessWin.cpp. (TEST):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@273784 268f45cc-cd09-0410-ab3c-d52691b4dbfc

3:22 PM Changeset in webkit [273924] by timothy_horton@apple.com
  • 2 edits in trunk/Source/WebKit

Fix the build after r273904

  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::setPreferenceValue):
auto's evilness rears its head again. -mutableCopy returns id, so
we infer RetainPtr<id>, so depending on what headers are included
we get ambiguous selector errors. De-auto to fix.

3:14 PM Changeset in webkit [273923] by Chris Dumez
  • 3 edits in trunk/Source/WebKit

Clean up API::ResourceLoadStatisticsThirdParty / API::ResourceLoadStatisticsFirstParty
https://bugs.webkit.org/show_bug.cgi?id=222701

Reviewed by Geoffrey Garen.

Clean up API::ResourceLoadStatisticsThirdParty / API::ResourceLoadStatisticsFirstParty:

  1. Make constructors private since there is a create() factory function.
  2. Mark constructor as explicit since they take a single parameter.
  3. Update ResourceLoadStatisticsFirstParty constructor to take parameter as a const reference instead of passing it by value.
  4. Add assertions to make sure those are constructed and destroyed on the main thread.
  • UIProcess/API/APIResourceLoadStatisticsFirstParty.h:
  • UIProcess/API/APIResourceLoadStatisticsThirdParty.h:
3:06 PM Changeset in webkit [273922] by Devin Rousso
  • 9 edits
    1 copy
    1 add in trunk/Source/WebCore

[Payment Request] increment the current version
https://bugs.webkit.org/show_bug.cgi?id=222742
<rdar://problem/74502674>

Reviewed by Wenson Hsieh.

  • Modules/applepay/cocoa/PaymentAPIVersionCocoa.mm:

(WebCore::PaymentAPIVersion::current):

  • testing/MockPaymentCoordinator.h:
  • testing/MockPaymentCoordinator.cpp:

(WebCore::MockPaymentCoordinator::showPaymentUI):
(WebCore::MockPaymentCoordinator::completeShippingMethodSelection):
(WebCore::MockPaymentCoordinator::completeShippingContactSelection):
(WebCore::MockPaymentCoordinator::completePaymentMethodSelection):
(WebCore::MockPaymentCoordinator::completePaymentMethodModeChange):

  • Modules/paymentrequest/PaymentRequestUtilities.h: Added.
  • Modules/paymentrequest/PaymentRequestUtilities.cpp: Added.

(isValidDecimalMonetaryValue):

  • Modules/paymentrequest/PaymentRequest.cpp:

(isValidDecimalMonetaryValue): Deleted.

  • Modules/applepay/ApplePaySession.cpp:

(convertAndValidateTotal):
(convertAndValidate):
(validateAmount): Deleted.

  • Modules/applepay/paymentrequest/ApplePayPaymentHandler.cpp:

Move isValidDecimalMonetaryValue so it can be used in other files.

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
3:06 PM Changeset in webkit [273921] by Russell Epstein
  • 5 edits
    4 adds in branches/safari-611.1.21.0-branch

Cherry-pick r273901. rdar://problem/75058982

window proxy of detached iframe doesn't respect updates to global values
https://bugs.webkit.org/show_bug.cgi?id=206445

Reviewed by Chris Dumez.

Source/WebCore:

According to the html spec the frame should only be needing for
COOP access violation reporting, which we don't support. This
patch removes our old behavior of blocking stores to windows that
have been detached.

I also removed some stale caching code from
getOwnPropertySlotByIndex since it's only accessed once now.

  • bindings/js/JSDOMWindowCustom.cpp: (WebCore::JSDOMWindow::getOwnPropertySlotByIndex): (WebCore::JSDOMWindow::doPutPropertySecurityCheck): (WebCore::JSDOMWindow::put): (WebCore::JSDOMWindow::putByIndex):

LayoutTests:

  • fast/frames/iframe-detached-window-still-writable-eval-expected.txt: Added.
  • fast/frames/iframe-detached-window-still-writable-eval.html: Added.
  • fast/frames/iframe-detached-window-still-writable-expected.txt: Added.
  • fast/frames/iframe-detached-window-still-writable.html: Added.
  • http/tests/dom/cross-origin-detached-window-properties-expected.txt:
  • http/tests/dom/cross-origin-detached-window-properties.html:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@273901 268f45cc-cd09-0410-ab3c-d52691b4dbfc

3:04 PM Changeset in webkit [273920] by Russell Epstein
  • 5 edits
    4 adds in branches/safari-611.1.21.1-branch

Cherry-pick r273901. rdar://problem/75058990

window proxy of detached iframe doesn't respect updates to global values
https://bugs.webkit.org/show_bug.cgi?id=206445

Reviewed by Chris Dumez.

Source/WebCore:

According to the html spec the frame should only be needing for
COOP access violation reporting, which we don't support. This
patch removes our old behavior of blocking stores to windows that
have been detached.

I also removed some stale caching code from
getOwnPropertySlotByIndex since it's only accessed once now.

  • bindings/js/JSDOMWindowCustom.cpp: (WebCore::JSDOMWindow::getOwnPropertySlotByIndex): (WebCore::JSDOMWindow::doPutPropertySecurityCheck): (WebCore::JSDOMWindow::put): (WebCore::JSDOMWindow::putByIndex):

LayoutTests:

  • fast/frames/iframe-detached-window-still-writable-eval-expected.txt: Added.
  • fast/frames/iframe-detached-window-still-writable-eval.html: Added.
  • fast/frames/iframe-detached-window-still-writable-expected.txt: Added.
  • fast/frames/iframe-detached-window-still-writable.html: Added.
  • http/tests/dom/cross-origin-detached-window-properties-expected.txt:
  • http/tests/dom/cross-origin-detached-window-properties.html:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@273901 268f45cc-cd09-0410-ab3c-d52691b4dbfc

2:51 PM Changeset in webkit [273919] by jonlee@apple.com
  • 2 edits in trunk/LayoutTests

Garden encrypted media tests
https://bugs.webkit.org/show_bug.cgi?id=221687

Reviewed by Simon Fraser.

  • platform/mac-wk2/TestExpectations: All but platform/mac/media/encrypted-media/fps-clearkey-crash.html are now passing. Remove expectations.
2:16 PM Changeset in webkit [273918] by Alan Bujtas
  • 4 edits
    2 adds in trunk

[LFC][IFC] LineStatus::availableWidth should always be a valid number
https://bugs.webkit.org/show_bug.cgi?id=222752
<rdar://problem/75028043>

Reviewed by Antti Koivisto.

Source/WebCore:

A NaN available width value can confuse the line breaking logic. This patch ensures we always provide a valid value.

Test: fast/inline/crash-when-negative-spacing-produce-nan.html

  • layout/inlineformatting/InlineContentBreaker.cpp:

(WebCore::Layout::InlineContentBreaker::processInlineContent):
(WebCore::Layout::InlineContentBreaker::processOverflowingContent const):

  • layout/inlineformatting/InlineLineBuilder.cpp:

(WebCore::Layout::LineBuilder::handleInlineContent):

LayoutTests:

  • fast/inline/crash-when-negative-spacing-produce-nan-expected.txt: Added.
  • fast/inline/crash-when-negative-spacing-produce-nan.html: Added.
2:05 PM Changeset in webkit [273917] by achristensen@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Unreviewed, reverting r273906.

Broke internal build

Reverted changeset:

"[Cocoa] REGRESSION(r272752): fix some internal builds that
use WTFString::WTFString(NSString *)"
https://bugs.webkit.org/show_bug.cgi?id=222610
https://commits.webkit.org/r273906

1:43 PM Changeset in webkit [273916] by achristensen@apple.com
  • 13 edits
    2 deletes in trunk/Source

Remove the HTTPSUpgradeEnabled experimental feature
https://bugs.webkit.org/show_bug.cgi?id=222706

Reviewed by Simon Fraser.

Source/WebKit:

  • NetworkProcess/NetworkHTTPSUpgradeChecker.cpp: Removed.
  • NetworkProcess/NetworkHTTPSUpgradeChecker.h: Removed.
  • NetworkProcess/NetworkLoadChecker.cpp:

(WebKit::NetworkLoadChecker::NetworkLoadChecker):
(WebKit::NetworkLoadChecker::checkRequest):
(WebKit::NetworkLoadChecker::applyHTTPSUpgradeIfNeeded const): Deleted.

  • NetworkProcess/NetworkLoadChecker.h:
  • NetworkProcess/NetworkProcess.h:
  • NetworkProcess/NetworkResourceLoadParameters.cpp:

(WebKit::NetworkResourceLoadParameters::encode const):
(WebKit::NetworkResourceLoadParameters::decode):

  • NetworkProcess/NetworkResourceLoadParameters.h:
  • NetworkProcess/NetworkResourceLoader.cpp:
  • NetworkProcess/cocoa/NetworkProcessCocoa.mm:

(WebKit::NetworkProcess::networkHTTPSUpgradeChecker): Deleted.

  • Sources.txt:
  • WebKit.xcodeproj/project.pbxproj:
  • WebProcess/Network/WebLoaderStrategy.cpp:

(WebKit::addParametersShared):

Source/WTF:

It was a good experimental implementation, but the feature is now implemented in makeSecureIfNecessary
and turned on and off by WKWebViewConfiguration.upgradeKnownHostsToHTTPS.

  • Scripts/Preferences/WebPreferencesExperimental.yaml:
1:06 PM Changeset in webkit [273915] by Wenson Hsieh
  • 3 edits in trunk/Source/WebKit

[iOS] Add support for a new image-extraction-related responder action
https://bugs.webkit.org/show_bug.cgi?id=222743
<rdar://problem/75001149>

Reviewed by Devin Rousso.

Add support for the new action, such that we return YES if and only if we're in an editable context, and also
such that we return a non-null target for the new action.

  • UIProcess/ios/WKContentViewInteraction.h:

Add a fallback definition for FOR_EACH_ADDITIONAL_WKCONTENTVIEW_ACTION, which can be used by WebKitAdditions
to inject additional responder actions when generating selector forwarding code between WKContentView and
WKWebView.

  • UIProcess/ios/WKContentViewInteraction.mm:

(-[WKContentView canPerformActionForWebView:withSender:]):

1:00 PM Changeset in webkit [273914] by Peng Liu
  • 2 edits in trunk/LayoutTests

[GPUP] Some media tests are flaky when media in GPU Process is enabled
https://bugs.webkit.org/show_bug.cgi?id=221693

Unreviewed test gardening.

Remove the tests which are consistently passing on bots from the test expectations.

  • platform/wk2/TestExpectations:
12:42 PM Changeset in webkit [273913] by aakash_jain@apple.com
  • 3 edits in trunk/Tools

[ews] Add python 3 support - part 5
https://bugs.webkit.org/show_bug.cgi?id=222744

Reviewed by Jonathan Bedard.

  • CISupport/ews-build/steps.py:

(CheckPatchRelevance._patch_is_relevant): Ensure that in python 3, path and changes are bytes. This is because buildbot
stores patch as bytes, as mentioned in https://github.com/buildbot/buildbot/issues/5812#issuecomment-790175979

  • CISupport/ews-build/steps_unittest.py: Updated one unit-test to test binary patch.
12:16 PM WebKitGTK/2.32.x edited by Michael Catanzaro
(diff)
12:12 PM Changeset in webkit [273912] by commit-queue@webkit.org
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: Persist CSS Grid overlay colors
https://bugs.webkit.org/show_bug.cgi?id=222319
<rdar://problem/74647242>

Patch by Razvan Caliman <Razvan Caliman> on 2021-03-04
Reviewed by Devin Rousso.

Save and restore CSS Grid overlay colors edited by a user.

  • UserInterface/Controllers/OverlayManager.js:

(WI.OverlayManager):
(WI.OverlayManager.prototype.showGridOverlay):
(WI.OverlayManager.prototype.getGridColorForNode):
(WI.OverlayManager.prototype.setGridColorForNode):
(WI.OverlayManager.prototype._handleMainResourceDidChange):

  • UserInterface/Views/CSSGridSection.js:

(WI.CSSGridSection.prototype.layout):

11:52 AM Changeset in webkit [273911] by Alan Coon
  • 2 edits in branches/safari-611.1.21.1-branch/Source/WebCore

Cherry-pick r273842. rdar://problem/75049285

Crash under SubresourceLoader::notifyDone()
https://bugs.webkit.org/show_bug.cgi?id=222683
<rdar://70342402>

Reviewed by Geoffrey Garen.

We were crashing doing a null-dereference of m_documentLoader under
SubresourceLoader::notifyDone(). This adds null checks for m_documentLoader
similarly to what is already done elsewhere in ResourceLoader.

No new tests, I do not know how to reproduce this.

  • loader/SubresourceLoader.cpp: (WebCore::SubresourceLoader::notifyDone):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@273842 268f45cc-cd09-0410-ab3c-d52691b4dbfc

11:51 AM Changeset in webkit [273910] by Alan Coon
  • 8 edits in branches/safari-611.1.21.1-branch/Source

Versioning.

WebKit-7611.1.21.1.5

11:46 AM Changeset in webkit [273909] by Alan Coon
  • 2 edits in branches/safari-611.1.21.0-branch/Source/WebCore

Cherry-pick r273842. rdar://problem/75049263

Crash under SubresourceLoader::notifyDone()
https://bugs.webkit.org/show_bug.cgi?id=222683
<rdar://70342402>

Reviewed by Geoffrey Garen.

We were crashing doing a null-dereference of m_documentLoader under
SubresourceLoader::notifyDone(). This adds null checks for m_documentLoader
similarly to what is already done elsewhere in ResourceLoader.

No new tests, I do not know how to reproduce this.

  • loader/SubresourceLoader.cpp: (WebCore::SubresourceLoader::notifyDone):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@273842 268f45cc-cd09-0410-ab3c-d52691b4dbfc

11:44 AM Changeset in webkit [273908] by Alan Coon
  • 8 edits in branches/safari-611.1.21.0-branch/Source

Versioning.

WebKit-7611.1.21.0.4

11:41 AM Changeset in webkit [273907] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

Unreviewed build fix after r272629.

  • UIProcess/Cocoa/WKBlankOverlayView.mm:
11:40 AM Changeset in webkit [273906] by achristensen@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

[Cocoa] REGRESSION(r272752): fix some internal builds that use WTFString::WTFString(NSString *)
https://bugs.webkit.org/show_bug.cgi?id=222610

Reviewed by Chris Dumez.

  • inspector/scripts/codegen/objc_generator.py:

(ObjCGenerator.objc_protocol_import_expression_for_member):
(ObjCGenerator.objc_protocol_import_expression_for_parameter):
(ObjCGenerator.protocol_to_objc_expression_for_member):
(ObjCGenerator.payload_to_objc_expression_for_member):

11:30 AM Changeset in webkit [273905] by youenn@apple.com
  • 3 edits
    3 adds in trunk

In case of POST navigation redirected by a 302, the 'Origin' header is kept in the redirected request
https://bugs.webkit.org/show_bug.cgi?id=222653
<rdar://problem/74983521>

Reviewed by Alex Christensen.

Source/WebCore:

Remove Origin header if the navigation request goes from POST to GET.
This aligns with other browsers and removes some known interop issues.
This is consistent with WebKit not sending Origin headers for GET navigations.

Test: http/wpt/fetch/navigation-post-to-get-origin.html

  • loader/DocumentLoader.cpp:

(WebCore::isRedirectToGetAfterPost):
(WebCore::DocumentLoader::willSendRequest):

LayoutTests:

  • http/wpt/fetch/echo-origin.py: Added.
  • http/wpt/fetch/navigation-post-to-get-origin-expected.txt: Added.
  • http/wpt/fetch/navigation-post-to-get-origin.html: Added.
11:02 AM Changeset in webkit [273904] by Chris Dumez
  • 11 edits in trunk

[macOS][WK2] Changing the system language does not update navigator.language
https://bugs.webkit.org/show_bug.cgi?id=222619

Reviewed by Per Arne Vollan.

Source/WebKit:

  • Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceMain.mm:

(WebKit::setAppleLanguagesPreference):
Fix a memory leak for newArguments.

  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::WebProcess::platformInitializeWebProcess):
If CFPREFS_DIRECT_MODE is not enabled, we need to listen for AppleLanguagePreferencesChangedNotification
inside the WebProcess. This used to happen implicitly inside WTF::platformUserPreferredLanguages() but
it is now explicit since we don't want/need it when using CFPREFS_DIRECT_MODE.

(WebKit::setPreferenceValue):

  • If preference is AppleLanguages, set it for the volatile domain to match what we do in XPCServiceMain.mm. This is needed because the preference in the volatile domain seems to take precedence.
  • Call WTF::languageDidChange() when the AppleLanguages preference gets updated so that language change listeners get notified of the language change (e.g. we fire a languagechange event at the Window).

Source/WebKitLegacy/mac:

We need to listen for AppleLanguagePreferencesChangedNotification on mac WK1.
This used to happen implicitly inside WTF::platformUserPreferredLanguages() but
it is now explicit since we don't want/need it when using CFPREFS_DIRECT_MODE in WK2.

  • WebView/WebView.mm:

(-[WebView _commonInitializationWithFrameName:groupName:]):

Source/WTF:

Update WTF::languageDidChange() to clear preferredLanguages() on Cocoa platforms
so that we get updated values from the system the next time
platformUserPreferredLanguages() is called.

platformUserPreferredLanguages() used to implicitly register a AppleLanguagePreferencesChangedNotification
listener. We've now made this registering opt-in by moving it to a separate
listenForLanguageChangeNotifications() function. This function is getting called
on Mac WK1 and WK2 when CFPREFS_DIRECT_MODE is disabled (legacy).
When CFPREFS_DIRECT_MODE is enabled in WK2, we don't want/need to listen for this
notification because the AppleLanguages preference gets pushed by the UIProcess
down to the WebProcesses. Even though we could listen for this notification,
the WebProcess would not have the latest AppleLanguages preference when receiving
the notification. This would cause us to fire the languagechange event at the
Window too early and navigator.language would keep returning the old language.
For WK2 with CFPREFS_DIRECT_MODE enabled, we now explicitly call
WTF::languageDidChange() when the "AppleLanguages" preference gets sync'd from
the UIProcess instead.

  • wtf/Language.cpp:

(WTF::languageDidChange):
(WTF::platformLanguageDidChange):

  • wtf/Language.h:
  • wtf/cf/LanguageCF.cpp:

(WTF::languagePreferencesDidChange):
(WTF::platformLanguageDidChange):
(WTF::listenForLanguageChangeNotifications):
(WTF::platformUserPreferredLanguages):

Tools:

Add API test coverage.

  • TestWebKitAPI/Tests/WebKit/OverrideAppleLanguagesPreference.mm:

(TEST):

10:41 AM Changeset in webkit [273903] by Chris Dumez
  • 14 edits in trunk/Source

Set ownership of IOSurfaces from the GPUProcess instead of the WebProcess
https://bugs.webkit.org/show_bug.cgi?id=222391
Source/WebCore:

<rdar://problem/74748353>

Reviewed by Simon Fraser.

Replace use of IOSurfaceSetOwnership() SPI with IOSurfaceSetOwnershipIdentity().
Both do the same thing but IOSurfaceSetOwnershipIdentity() only requires an identity token
for the new owner (instead of a control port). As a result, IOSurfaceSetOwnershipIdentity()
requires a lot less priviledges and can now be used directly in the GPUProcess instead of
the WebProcess.

  • platform/graphics/cocoa/IOSurface.h:
  • platform/graphics/cocoa/IOSurface.mm:

(WebCore::IOSurface::setOwnershipIdentity):

Source/WebCore/PAL:

<rdar://74748353>

Reviewed by Simon Fraser.

Add declaration for new IOSurfaceSetOwnershipIdentity() SPI, for the open source
SDK.

  • pal/spi/cocoa/IOSurfaceSPI.h:

Source/WebKit:

<rdar://problem/74748353>

Reviewed by Simon Fraser.

Replace use of IOSurfaceSetOwnership() SPI with IOSurfaceSetOwnershipIdentity().
Both do the same thing but IOSurfaceSetOwnershipIdentity() only requires an identity token
for the new owner (instead of a control port). As a result, IOSurfaceSetOwnershipIdentity()
requires a lot less priviledges and can now be used directly in the GPUProcess instead of
the WebProcess.

  • GPUProcess/graphics/RemoteGraphicsContextGLCocoa.cpp:

(WebKit::RemoteGraphicsContextGLCocoa::prepareForDisplay):

  • GPUProcess/graphics/RemoteImageBuffer.h:

(WebKit::RemoteImageBuffer::setProcessOwnership):

  • GPUProcess/graphics/RemoteRenderingBackend.cpp:

(WebKit::RemoteRenderingBackend::createImageBuffer):

  • WebProcess/GPU/graphics/RemoteGraphicsContextGLProxy.cpp:

(WebKit::RemoteGraphicsContextGLProxy::prepareForDisplay):

  • WebProcess/GPU/graphics/cocoa/ImageBufferShareableMappedIOSurfaceBackend.cpp:

(WebKit::ImageBufferShareableMappedIOSurfaceBackend::create):
(WebKit::ImageBufferShareableMappedIOSurfaceBackend::setProcessOwnership):

  • WebProcess/GPU/graphics/cocoa/ImageBufferShareableMappedIOSurfaceBackend.h:

Source/WTF:

<rdar://74748353>

Reviewed by Simon Fraser.

Add HAVE_IOSURFACE_SET_OWNERSHIP_IDENTITY feature flag to protect uses of the
new IOSurfaceSetOwnershipIdentity() SPI.

  • wtf/PlatformHave.h:
10:28 AM Changeset in webkit [273902] by Said Abou-Hallawa
  • 3 edits in trunk/LayoutTests

Followup (r273764): Use different container sizes in background-svg-image-loading.html
https://bugs.webkit.org/show_bug.cgi?id=222679

Reviewed by Antti Koivisto.

This will force different SVGImageForContainers in SVGImageCache one for
each SVGImage client (<div> element in this test).

  • fast/css/background-svg-image-loading-expected.html:
  • fast/css/background-svg-image-loading.html:
10:26 AM Changeset in webkit [273901] by keith_miller@apple.com
  • 5 edits
    4 adds in trunk

window proxy of detached iframe doesn't respect updates to global values
https://bugs.webkit.org/show_bug.cgi?id=206445

Reviewed by Chris Dumez.

Source/WebCore:

According to the html spec the frame should only be needing for
COOP access violation reporting, which we don't support. This
patch removes our old behavior of blocking stores to windows that
have been detached.

I also removed some stale caching code from
getOwnPropertySlotByIndex since it's only accessed once now.

  • bindings/js/JSDOMWindowCustom.cpp:

(WebCore::JSDOMWindow::getOwnPropertySlotByIndex):
(WebCore::JSDOMWindow::doPutPropertySecurityCheck):
(WebCore::JSDOMWindow::put):
(WebCore::JSDOMWindow::putByIndex):

LayoutTests:

  • fast/frames/iframe-detached-window-still-writable-eval-expected.txt: Added.
  • fast/frames/iframe-detached-window-still-writable-eval.html: Added.
  • fast/frames/iframe-detached-window-still-writable-expected.txt: Added.
  • fast/frames/iframe-detached-window-still-writable.html: Added.
  • http/tests/dom/cross-origin-detached-window-properties-expected.txt:
  • http/tests/dom/cross-origin-detached-window-properties.html:
10:19 AM Changeset in webkit [273900] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Audits Tab: nothing happens when clicking "Start" button in the content area placeholder text
https://bugs.webkit.org/show_bug.cgi?id=222740
rdar://75008042

Patch by Razvan Caliman <Razvan Caliman> on 2021-03-04
Reviewed by Devin Rousso.

  • UserInterface/Views/AuditTestContentView.js:

(WI.AuditTestContentView.prototype.showNoResultPlaceholder):

10:10 AM Changeset in webkit [273899] by jonlee@apple.com
  • 2 edits in trunk/LayoutTests

Garden GPU Process TestExpectations
https://bugs.webkit.org/show_bug.cgi?id=222729

Reviewed by Said Abou-Hallawa.

  • gpu-process/TestExpectations: Complete filing bugs for failing tests.

Remove expectations for some tests which are now passing on the bot.

10:08 AM Changeset in webkit [273898] by Robert Jenner
  • 2 edits in trunk/LayoutTests

[ macOS ] inspector/page/empty-or-missing-resources.html is a flakey timeout
https://bugs.webkit.org/show_bug.cgi?id=222692

Unreviewed test gardening.

  • platform/mac/TestExpectations: Updating test expectations until test flakiness can be resolved.
10:00 AM Changeset in webkit [273897] by commit-queue@webkit.org
  • 14 edits in trunk

Introduce "websocket", "fetch", and "other" resource types to WKContentRuleList
https://bugs.webkit.org/show_bug.cgi?id=222709
<rdar://problem/71552078>

Patch by Alex Christensen <achristensen@webkit.org> on 2021-03-04
Reviewed by Youenn Fablet.

Source/WebCore:

"raw" didn't give the desired granularity. This keeps support for "raw", but splits it into 3 subcategories:
"websocket" which only applies to WebSocket requests,
"fetch" which applies to XMLHTTPRequest and fetch API requests.
"other" which applies to other "raw" requests, such as beacons.

Covered by API tests.

  • Modules/websockets/ThreadableWebSocketChannel.cpp:

(WebCore::ThreadableWebSocketChannel::validateURL):

  • contentextensions/ContentExtensionParser.cpp:

(WebCore::ContentExtensions::getTypeFlags):

  • css/StyleSheetContents.cpp:

(WebCore::StyleSheetContents::subresourcesAllowReuse const):

  • loader/NetscapePlugInStreamLoader.cpp:

(WebCore::NetscapePlugInStreamLoader::NetscapePlugInStreamLoader):

  • loader/ResourceLoadInfo.cpp:

(WebCore::ContentExtensions::toResourceType):
(WebCore::ContentExtensions::readResourceType):
(WebCore::ContentExtensions::readLoadType):
(WebCore::ContentExtensions::ResourceLoadInfo::getResourceFlags const):

  • loader/ResourceLoadInfo.h:
  • loader/ResourceLoader.cpp:

(WebCore::ResourceLoader::willSendRequestInternal):

  • loader/ResourceLoader.h:
  • loader/SubresourceLoader.cpp:

(WebCore::SubresourceLoader::SubresourceLoader):

  • loader/cache/CachedResourceLoader.cpp:

(WebCore::CachedResourceLoader::requestResource):

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/ContentRuleListNotification.mm:

(TEST):
(webSocketAcceptValue):

  • TestWebKitAPI/cocoa/HTTPServer.mm:

(TestWebKitAPI::statusText):

9:57 AM Changeset in webkit [273896] by graouts@webkit.org
  • 2 edits in trunk/Source/WebCore

Adjust progress parameter before calling blend() for discrete interpolations
https://bugs.webkit.org/show_bug.cgi?id=222736

Reviewed by Antti Koivisto.

In the case of discrete interpolation, we must treat progress as 0 for progress < 0.5
and 1 otherwise. Currently we do it separately in at two places. So that we don't do
it in more places, let's do this directly in CSSPropertyAnimation::blendProperties()
so that the progress is already set before any of the blend() methods are called.

  • animation/CSSPropertyAnimation.cpp:

(WebCore::CSSPropertyAnimation::blendProperties):

9:55 AM Changeset in webkit [273895] by Peng Liu
  • 8 edits
    2 deletes in trunk

[GPUProcess] MediaController is using a ClockCM
https://bugs.webkit.org/show_bug.cgi?id=222094

Reviewed by Eric Carlson.

Source/WebCore:

No new tests. Fix test failures.

  • html/MediaController.cpp: Some minor clean-up.
  • platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h:

A minor clean-up.

Source/WebCore/PAL:

Remove ClockCM and use ClockGeneric instead because ClockCM::currentTime()
always returns NaN when "Media in GPU Process" is enabled.

  • PAL.xcodeproj/project.pbxproj:
  • pal/PlatformMac.cmake:
  • pal/system/mac/ClockCM.h: Removed.
  • pal/system/mac/ClockCM.mm: Removed.

LayoutTests:

  • platform/wk2/TestExpectations:
9:49 AM Changeset in webkit [273894] by youenn@apple.com
  • 2 edits in trunk/Source/WebCore

AVAudioSessionCaptureDeviceManager::retrieveAudioSessionCaptureDevices is unnecessarily creating a NSArray twice
https://bugs.webkit.org/show_bug.cgi?id=222732

Reviewed by Eric Carlson.

Before the patch, [m_audioSession availableInputs] was called twice.
This creates two NSArray which is not create from a memory standpoint.
There is also the risk that the two NSArrays have two different size, in which case Vector::uncheckedAppend would fail.

Cannot be easily tested, no observable change expected.

  • platform/mediastream/ios/AVAudioSessionCaptureDeviceManager.mm:

(WebCore::AVAudioSessionCaptureDeviceManager::retrieveAudioSessionCaptureDevices const):

9:49 AM Changeset in webkit [273893] by youenn@apple.com
  • 2 edits in trunk/Source/ThirdParty/libwebrtc

Use NO_MAIN_THREAD_WRAPPING to compile libwebrtc
https://bugs.webkit.org/show_bug.cgi?id=222717
<rdar://problem/74988599>

Reviewed by Eric Carlson.

  • Configurations/libwebrtc.xcconfig:

This prevents creating socket server in Web Process.

9:48 AM Changeset in webkit [273892] by youenn@apple.com
  • 5 edits in trunk/Source/WebKit

REGRESSION (r273732): ASSERTION FAILED: Completion handler should always be called under WebKit::RemoteRealtimeMediaSourceProxy::~RemoteRealtimeMediaSourceProxy
https://bugs.webkit.org/show_bug.cgi?id=222691
<rdar://problem/75006211>

Reviewed by Eric Carlson.

Make sure to return a ApplyConstraints completed message in all cases.
Call completion handler when source gets destroyed.
Covered by existing tests.

  • UIProcess/Cocoa/UserMediaCaptureManagerProxy.cpp:

(WebKit::UserMediaCaptureManagerProxy::applyConstraints):

  • WebProcess/cocoa/RemoteRealtimeMediaSourceProxy.cpp:

(WebKit::RemoteRealtimeMediaSourceProxy::~RemoteRealtimeMediaSourceProxy):

  • WebProcess/cocoa/RemoteRealtimeMediaSourceProxy.h:
  • WebProcess/cocoa/RemoteRealtimeVideoSource.cpp:

(WebKit::RemoteRealtimeVideoSource::gpuProcessConnectionDidClose):

8:44 AM Changeset in webkit [273891] by youenn@apple.com
  • 30 edits in trunk

Update camera and microphone capture state control WKWebView API
https://bugs.webkit.org/show_bug.cgi?id=222166

Reviewed by Eric Carlson.

Source/WebCore:

Introduce the possibility to mute either camera and/or microphone capture independently.
Covered by existing tests.

  • Modules/mediastream/MediaStreamTrack.cpp:

(WebCore::MediaStreamTrack::updateCaptureAccordingToMutedState):
(WebCore::MediaStreamTrack::updateToPageMutedState):
(WebCore::trackMatchesKind):
(WebCore::MediaStreamTrack::endCapture):

  • Modules/mediastream/MediaStreamTrack.h:
  • dom/Document.cpp:

(WebCore::Document::stopMediaCapture):

  • dom/Document.h:
  • page/MediaProducer.h:
  • page/Page.cpp:

(WebCore::Page::stopMediaCapture):

  • page/Page.h:

Source/WebKit:

Introduce KVO states for microphone and camera capture states.
Add two APIs to set microphone and camera state.
This allows to mute/unmute or stop microphone or camera state.
We needed to introduce muting of either microphone or camera since this was tied together before the patch.
These two APIs take a completion handler.

  • UIProcess/API/Cocoa/WKUIDelegatePrivate.h:
  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _cameraCaptureState]):
(-[WKWebView _microphoneCaptureState]):
(-[WKWebView setMicrophoneCaptureState:completionHandler:]):
(-[WKWebView setCameraCaptureState:completionHandler:]):
(-[WKWebView _stopMediaCapture]):
(-[WKWebView _mediaCaptureState]):

  • UIProcess/API/Cocoa/WKWebViewPrivate.h:
  • UIProcess/Cocoa/MediaUtilities.h:
  • UIProcess/Cocoa/MediaUtilities.mm:

(WebKit::toWKMediaCaptureStateDeprecated):
(WebKit::toWKMediaCaptureState): Deleted.

  • UIProcess/Cocoa/PageClientImplCocoa.h:
  • UIProcess/Cocoa/PageClientImplCocoa.mm:

(WebKit::PageClientImplCocoa::microphoneCaptureChanged):
(WebKit::PageClientImplCocoa::cameraCaptureChanged):

  • UIProcess/Cocoa/UIDelegate.mm:

(WebKit::UIDelegate::UIClient::mediaCaptureStateDidChange):

  • UIProcess/PageClient.h:

(WebKit::PageClient::microphoneCaptureChanged):
(WebKit::PageClient::cameraCaptureChanged):

  • UIProcess/UserMediaPermissionRequestManagerProxy.cpp:

(WebKit::UserMediaPermissionRequestManagerProxy::~UserMediaPermissionRequestManagerProxy):
(WebKit::UserMediaPermissionRequestManagerProxy::stopCapture):

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::setMuted):
(WebKit::WebPageProxy::stopMediaCapture):
(WebKit::WebPageProxy::updateReportedMediaCaptureState):

  • UIProcess/WebPageProxy.h:

(WebKit::WebPageProxy::setMuted):
(WebKit::WebPageProxy::stopMediaCapture):

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::m_lastNavigationWasAppBound):
(WebKit::WebPage::setMuted):
(WebKit::WebPage::stopMediaCapture):

  • WebProcess/WebPage/WebPage.h:
  • WebProcess/WebPage/WebPage.messages.in:

Tools:

Updaed according renaming of _WKMediaCaptureState in _WKMediaCaptureStateDeprecated.

  • TestWebKitAPI/Tests/WebKit/GetUserMedia.mm:

(TestWebKitAPI::wkMediaCaptureStateString):
(TestWebKitAPI::waitUntilCaptureState):
(TestWebKitAPI::TEST):

  • TestWebKitAPI/Tests/WebKit/MediaStreamTrackDetached.mm:

(-[MediaStreamTrackDetachedUIDelegate _webView:mediaCaptureStateDidChange:]):

  • TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:

(-[GetUserMediaUIDelegate _webView:mediaCaptureStateDidChange:]):

  • TestWebKitAPI/Tests/WebKitCocoa/SpeechRecognition.mm:

(-[SpeechRecognitionUIDelegate _webView:mediaCaptureStateDidChange:]):

  • WebKitTestRunner/cocoa/TestControllerCocoa.mm:

(WTR::TestController::isDoingMediaCapture const):

8:32 AM Changeset in webkit [273890] by youenn@apple.com
  • 3 edits
    2 adds in trunk

Handle the case of synchronous failure in loading blob.
https://bugs.webkit.org/show_bug.cgi?id=222724

Reviewed by Carlos Garcia Campos.

Source/WebCore:

Test: http/tests/fetch/blob-in-unload-event-handler.html

  • fileapi/Blob.cpp:

(WebCore::Blob::stream):
In case of synchronous failure, wait for the stream to be started to error it.

LayoutTests:

  • http/tests/fetch/blob-in-unload-event-handler-expected.txt: Added.
  • http/tests/fetch/blob-in-unload-event-handler.html: Added.
8:26 AM Changeset in webkit [273889] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC][IFC] LineBox::m_rootInlineBox does not need to be a UniqueRef
https://bugs.webkit.org/show_bug.cgi?id=222705

Reviewed by Antti Koivisto.

  • layout/inlineformatting/InlineLineBox.cpp:

(WebCore::Layout::m_rootInlineBox):
(WebCore::Layout::LineBox::logicalRectForTextRun const):
(WebCore::Layout::LineBox::logicalRectForInlineLevelBox const):

  • layout/inlineformatting/InlineLineBox.h:

(WebCore::Layout::LineBox::logicalRectForRootInlineBox const):
(WebCore::Layout::LineBox::alignmentBaseline const):
(WebCore::Layout::LineBox::inlineLevelBoxForLayoutBox):

6:23 AM Changeset in webkit [273888] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] InlineContentBuilder::createDisplayNonRootInlineBoxes should check if the line has inline boxes at all
https://bugs.webkit.org/show_bug.cgi?id=222707

Reviewed by Antti Koivisto.

  • layout/integration/LayoutIntegrationInlineContentBuilder.cpp:

(WebCore::LayoutIntegration::InlineContentBuilder::createDisplayNonRootInlineBoxes const):

6:22 AM Changeset in webkit [273887] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC][IFC] Make LineBox::m_inlineLevelBoxRectMap a non-root inline level box map
https://bugs.webkit.org/show_bug.cgi?id=222704

Reviewed by Antti Koivisto.

Let's not trigger hash lookup for the most common inlineLevelBoxForLayoutBox() call (when we lookup the root inline box
as the parent of a text content).

  • layout/inlineformatting/InlineLineBox.cpp:

(WebCore::Layout::LineBox::addInlineLevelBox):

  • layout/inlineformatting/InlineLineBox.h:

(WebCore::Layout::LineBox::inlineLevelBoxForLayoutBox const):
(WebCore::Layout::LineBox::inlineLevelBoxForLayoutBox):

5:53 AM Changeset in webkit [273886] by commit-queue@webkit.org
  • 3 edits
    2 adds in trunk

Null check platformData when decoding
https://bugs.webkit.org/show_bug.cgi?id=221442

Patch by Rob Buis <rbuis@igalia.com> on 2021-03-04
Reviewed by Ryosuke Niwa.

Source/WebKit:

Null check platformData when decoding.

Test: ipc/pasteboard-write-custom-data.html

  • Shared/WebCoreArgumentCoders.cpp:

(IPC::ArgumentCoder<PasteboardCustomData::Entry>::decode):

LayoutTests:

Add test for this.

  • ipc/pasteboard-write-custom-data-expected.txt: Added.
  • ipc/pasteboard-write-custom-data.html: Added.
5:22 AM Changeset in webkit [273885] by commit-queue@webkit.org
  • 12 edits
    2 adds in trunk/Source/WebCore

[Nicosia] Move shared scrolling animation code into a ScrollingTreeScrollingNodeDelegate
https://bugs.webkit.org/show_bug.cgi?id=222714

Patch by Martin Robinson <mrobinson@igalia.com> on 2021-03-04
Reviewed by Žan Doberšek.

No new tests. This should not change behavior.

  • PlatformMac.cmake: Remove delegate parent class from Mac-specific list.
  • PlatformPlayStation.cmake: Added new class to source list.
  • Sources.txt: Added delegate parent class to shared source list.
  • SourcesGTK.txt: Added new class.
  • SourcesWPE.txt: Ditto.
  • WebCore.xcodeproj/project.pbxproj: Remove source file from project, since

it is now in Sources.txt.

  • page/scrolling/ScrollingTreeScrollingNodeDelegate.cpp: Changed import to include.
  • page/scrolling/nicosia/ScrollingTreeFrameScrollingNodeNicosia.cpp:

Moved shared code to ScrollingTreeScrollingNodeDelegate.

  • page/scrolling/nicosia/ScrollingTreeFrameScrollingNodeNicosia.h: Ditto.
  • page/scrolling/nicosia/ScrollingTreeOverflowScrollingNodeNicosia.cpp: Ditto.
  • page/scrolling/nicosia/ScrollingTreeOverflowScrollingNodeNicosia.h: Dito.
  • page/scrolling/nicosia/ScrollingTreeScrollingNodeDelegateNicosia.cpp: Added

shared code from ScrollingTreeFrameScrollingNodeNicosia and ScrollingTreeOverflowScrollingNodeNicosia

  • page/scrolling/nicosia/ScrollingTreeScrollingNodeDelegateNicosia.h: Added.
5:18 AM Changeset in webkit [273884] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

REGRESSION(r273644 ): [GStreamer] new webrtc failures
https://bugs.webkit.org/show_bug.cgi?id=222649

Patch by Philippe Normand <pnormand@igalia.com> on 2021-03-04
Reviewed by Xabier Rodriguez-Calvar.

Since the mediastreamsrc element maintains static source pads, it now needs to remove pads
left unused resulting from a track removal.

  • platform/mediastream/gstreamer/GStreamerMediaStreamSource.cpp:

(webkitMediaStreamSrcRemovePad):
(webkitMediaStreamSrcRemoveTrackByType):

5:01 AM Changeset in webkit [273883] by commit-queue@webkit.org
  • 2 edits in trunk/Tools

Detect unrecognized options in run-javascriptcore-tests
https://bugs.webkit.org/show_bug.cgi?id=221186

Patch by Angelos Oikonomopoulos <Angelos Oikonomopoulos> on 2021-03-04
Reviewed by Keith Miller.

run-javascriptcore-tests saves unrecognized arguments to pass
through to build-jsc even when --no-build is used. However, when
we're not building, nothing will ever use or look at the extra
arguments. This means that those arguments are silently eaten
up and, consequently, typos in option names can go undetected.

Change the script to fail when --no-build has been passed and
there are unrecognized options.

  • Scripts/run-javascriptcore-tests:
3:26 AM Changeset in webkit [273882] by graouts@webkit.org
  • 20 edits in trunk

initial value for border-image-outset should be 0
https://bugs.webkit.org/show_bug.cgi?id=222721

Reviewed by Antti Koivisto.

LayoutTests/imported/w3c:

Pass one extra WPT test.

  • web-platform-tests/css/css-backgrounds/inheritance.sub-expected.txt:
  • web-platform-tests/css/cssom/cssstyledeclaration-csstext-expected.txt:

Source/WebCore:

The initial value for border-image-outset was a Length with Fixed type (0px)
instead of Relative type (0).

  • rendering/style/NinePieceImage.h:
  • style/StyleBuilderCustom.h:

(WebCore::Style::ApplyPropertyBorderImageModifier::applyInitialValue):

LayoutTests:

Update some tests to make the correct assumption on the border-image-ouset initial value.

  • css3/calc/reflection-computed-style-expected.txt:
  • fast/css/getComputedStyle/computed-style-border-image-expected.txt:
  • fast/css/getComputedStyle/computed-style-border-image.html:
  • fast/css/getComputedStyle/computed-style-with-zoom-expected.txt:
  • fast/css/getComputedStyle/getComputedStyle-border-image-expected.txt:
  • fast/reflections/reflection-computed-style-expected.txt:
  • platform/ios-wk2/imported/w3c/web-platform-tests/css/cssom/cssstyledeclaration-csstext-expected.txt:
  • platform/ios/fast/css/getComputedStyle/computed-style-expected.txt:
  • platform/ios/fast/css/getComputedStyle/computed-style-without-renderer-expected.txt:
  • platform/ios/svg/css/getComputedStyle-basic-expected.txt:
  • platform/mac/fast/css/getComputedStyle/computed-style-expected.txt:
  • platform/mac/fast/css/getComputedStyle/computed-style-without-renderer-expected.txt:
  • platform/mac/svg/css/getComputedStyle-basic-expected.txt:
1:39 AM Changeset in webkit [273881] by youenn@apple.com
  • 3 edits
    3 adds in trunk

FileReader::enqueueTask should validate that its context is not stopped before executing the task
https://bugs.webkit.org/show_bug.cgi?id=222472
Source/WebCore:

Reviewed by Alex Christensen.

The event loop might run tasks even though active dom objects are stopped.
Protect from this by adding a check since m_state checks are not sufficient.
A follow-up patch should probably try to neuter FileReader if it is stopped.

Covered by http/wpt/filereader/filereader-stop.html.

  • fileapi/FileReader.cpp:

(WebCore::FileReader::fireEvent):
(WebCore::FileReader::enqueueTask):

LayoutTests:

<rdar://problem/74753571>

Reviewed by Alex Christensen.

  • http/wpt/filereader/filereader-stop.html: Added.
1:39 AM Changeset in webkit [273880] by Chris Lord
  • 3 edits in trunk/Source/WebCore

Make the data backing generated global AtomString values accessible
https://bugs.webkit.org/show_bug.cgi?id=222552

Reviewed by Darin Adler.

Modify name header generation script to make the const string data public.

No new tests because there is no behavior change.

  • bindings/scripts/StaticString.pm:

(GenerateStrings):

  • dom/make_names.pl:
1:32 AM Changeset in webkit [273879] by youenn@apple.com
  • 4 edits
    4 adds in trunk

Can not read blobs in sandboxed iframes
https://bugs.webkit.org/show_bug.cgi?id=170075
<rdar://problem/31282427>

Reviewed by Alex Christensen.

Source/WebCore:

In case of blob with an opaque origin, get the document that created the blob and use the document for mixed content check.
Further refactoring should be done once specs are updated to clarify this.
See https://github.com/w3c/webappsec-mixed-content/issues/41 for more information.

Tests: http/wpt/fetch/blob-of-opaque-origin-iframe.html

http/wpt/fetch/blob-of-opaque-origin-worker.html

  • loader/MixedContentChecker.cpp:

(WebCore::MixedContentChecker::isMixedContent):

LayoutTests:

  • http/wpt/fetch/blob-of-opaque-origin-iframe-expected.txt: Added.
  • http/wpt/fetch/blob-of-opaque-origin-iframe.html: Added.
  • http/wpt/fetch/blob-of-opaque-origin-worker-expected.txt: Added.
  • http/wpt/fetch/blob-of-opaque-origin-worker.html: Added.
  • platform/win/TestExpectations:
1:09 AM Changeset in webkit [273878] by commit-queue@webkit.org
  • 7 edits in trunk/Source/WebKit

IPC stream feature should use client/server naming instead of sender/receiver
https://bugs.webkit.org/show_bug.cgi?id=222592

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2021-03-04
Reviewed by Antti Koivisto.

Attempt to simplify already complicated implementation of the stream
implementation. Uses of "sender" and "receiver" were a leftover from
early phase of the implementation.

Rename all remaining instances of "sender" with "client".
Rename all remaining instances of "receiver" with "server".

No new tests, a refactor.

  • Platform/IPC/StreamClientConnection.cpp:

(IPC::StreamClientConnection::StreamClientConnection):
(IPC::StreamClientConnection::setWakeUpSemaphore):
(IPC::StreamClientConnection::wakeUpServer):

  • Platform/IPC/StreamClientConnection.h:

(IPC::StreamClientConnection::send):
(IPC::StreamClientConnection::trySendDestinationIDIfNeeded):
(IPC::StreamClientConnection::tryAcquire):
(IPC::StreamClientConnection::release):

  • Platform/IPC/StreamConnectionBuffer.cpp:

(IPC::StreamConnectionBuffer::StreamConnectionBuffer):
(IPC::StreamConnectionBuffer::operator=):
(IPC::StreamConnectionBuffer::encode const):

  • Platform/IPC/StreamConnectionBuffer.h:

(IPC::StreamConnectionBuffer::clientOffset):
(IPC::StreamConnectionBuffer::serverOffset):
(IPC::StreamConnectionBuffer::clientWaitSemaphore):
(IPC::StreamConnectionBuffer::maximumSize):

  • Platform/IPC/StreamServerConnection.cpp:

(IPC::StreamServerConnectionBase::tryAquire):
(IPC::StreamServerConnectionBase::release):

  • Platform/IPC/StreamServerConnection.h:

(IPC::StreamServerConnectionBase::sharedClientOffset):
(IPC::StreamServerConnectionBase::sharedServerOffset):

1:00 AM Changeset in webkit [273877] by commit-queue@webkit.org
  • 24 edits in trunk

Adding new test conditions for WebGL should be simpler
https://bugs.webkit.org/show_bug.cgi?id=222593

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2021-03-04
Reviewed by Kenneth Russell.

Source/WebCore:

Replace Internals functions:

Internals.setFailNextGPUStatusCheck()
Internals.simulateContextChanged()

with

Internals.simulateEventForWebGLContext(SimulatedWebGLContextEvent, WebGLRenderingContext)

Most envisioned test simulation environment triggers do not need parameters. It is simpler
to implement the triggers from one call site.

No new tests, a refactor.

  • html/canvas/WebGLRenderingContextBase.cpp:

(WebCore::WebGLRenderingContextBase::simulateEventForTesting):

  • html/canvas/WebGLRenderingContextBase.h:
  • platform/graphics/GraphicsContextGL.h:
  • platform/graphics/cocoa/GraphicsContextGLOpenGLCocoa.mm:

(WebCore::GraphicsContextGLOpenGL::simulateEventForTesting):

  • platform/graphics/opengl/GraphicsContextGLOpenGL.cpp:

(WebCore::GraphicsContextGLOpenGL::simulateEventForTesting):

  • platform/graphics/opengl/GraphicsContextGLOpenGL.h:
  • testing/Internals.h:
  • testing/Internals.idl:

Implement the feature by replacing

Internals.setFailNextGPUStatusCheck()
Internals.simulateContextChanged()

with

Internals.simulateEventForWebGLContext(SimulatedWebGLContextEvent, WebGLRenderingContext)

with eventName taking invented events that can happen to a
webgl context:

"GPUStatusFailure" and "ContextChange".

Future commits will add at least "Timeout".

The Internals function name was chosen not to contain "ForTesting" suffix, as
all the functions in the class should have that suffix.
The function names in the implementation path for the feature contains
"ForTesting" in order to highlight the feature not being in the normal
path.

Source/WebKit:

Replace simulateContextChanged and
setFailNextGPUStatusCheck with simulateEventForTesting.

  • GPUProcess/graphics/RemoteGraphicsContextGL.cpp:

(WebKit::RemoteGraphicsContextGL::simulateEventForTesting):

  • GPUProcess/graphics/RemoteGraphicsContextGL.h:
  • GPUProcess/graphics/RemoteGraphicsContextGL.messages.in:
  • GPUProcess/graphics/RemoteGraphicsContextGLFunctionsGenerated.h:
  • WebProcess/GPU/graphics/RemoteGraphicsContextGLProxy.cpp:

(WebKit::RemoteGraphicsContextGLProxy::simulateEventForTesting):

  • WebProcess/GPU/graphics/RemoteGraphicsContextGLProxy.h:
  • WebProcess/GPU/graphics/RemoteGraphicsContextGLProxyFunctionsGenerated.cpp:

Tools:

Add SimulateEventForTesting(String eventName) to manually
implemented RemoteGraphicsContextGL functions.
Use manually generated function because next commit for
timeout implementation will add some logic to RemoteGraphicsContextGL
while forwarding rest of the events to the underlying GraphicsContextGL.

  • Scripts/generate-gpup-webgl:

LayoutTests:

  • fast/canvas/webgl/webglcontextchangedevent.html:

Replace internals.simulateContextChanged(context) with
internals.simulateEventForWebGLContext("ContextChange", context)

  • fast/canvas/webgl/lose-context-on-status-failure.html:

Similarly replace internals.setFailNextGPUStatusCheck(context) with
internals.simulateEventForWebGLContext("GPUStatusFailure", context).

12:48 AM Changeset in webkit [273876] by svillar@igalia.com
  • 2 edits in trunk/LayoutTests

ASSERTION FAILED: contentSize >= 0 in WefbCore::RenderFlexibleBox::adjustChildSizeForMinAndMax
https://bugs.webkit.org/show_bug.cgi?id=222711

Unreviewed test gardening.

  • TestExpectations: Adding a test that is ASSERTing in Debug builds since it was imported.

Mar 3, 2021:

11:22 PM Changeset in webkit [273875] by commit-queue@webkit.org
  • 6 edits in trunk

WKRemoteObjectCoder should be able to handle NSErrors from TLS failures
https://bugs.webkit.org/show_bug.cgi?id=222401
Source/WebKit:

<rdar://problem/72103865>

Patch by Alex Christensen <achristensen@webkit.org> on 2021-03-03
Reviewed by Chris Dumez.

NSErrors from TLS failures contain values like a SecTrustRef or a SecCertificateRef,
which are not ObjC objects, and they don't like it when you call encodeWithCoder: on them.
Until r273141 it would crash when we do, but even after that we just decode a nil NSError.
Add a special case like we did in encodeNSError to successfully encode and decode these errors.

  • Shared/API/Cocoa/WKRemoteObjectCoder.mm:

(decodeObjCObject):
(transformCertificatesToData):
(transformTrustToData):
(encodeError):
(transformDataToCertificates):
(transformDataToTrust):
(decodeError):
(encodeObject):
(decodeObject):

Tools:

Patch by Alex Christensen <achristensen@webkit.org> on 2021-03-03
Reviewed by Chris Dumez.

  • TestWebKitAPI/Tests/WebKitCocoa/RemoteObjectRegistry.h:
  • TestWebKitAPI/Tests/WebKitCocoa/RemoteObjectRegistry.mm:

(TEST):

  • TestWebKitAPI/Tests/WebKitCocoa/RemoteObjectRegistryPlugIn.mm:

(-[RemoteObjectRegistryPlugIn sendError:completionHandler:]):

10:13 PM Changeset in webkit [273874] by ysuzuki@apple.com
  • 7 edits
    1 copy
    4 adds
    1 delete in trunk/JSTests

[JSC] Update test262
https://bugs.webkit.org/show_bug.cgi?id=222710

Reviewed by Ross Kirsling.

Update test262. New failure is due to the spec change, tracked in https://bugs.webkit.org/show_bug.cgi?id=222526.

  • test262/expectations.yaml:
  • test262/latest-changes-summary.txt:
  • test262/test/built-ins/Array/prototype/sort/call-with-primitive.js: Added.
  • test262/test/built-ins/Function/internals/Call/class-ctor-realm.js:
  • test262/test/language/expressions/object/dstr/object-rest-proxy-get-not-called-on-dontenum-keys.js: Added.

(getOwnPropertyDescriptor):
(ownKeys):

  • test262/test/language/expressions/object/dstr/object-rest-proxy-gopd-not-called-on-excluded-keys.js: Added.

(getOwnPropertyDescriptor):
(ownKeys):

  • test262/test/language/expressions/object/object-spread-proxy-get-not-called-on-dontenum-keys.js: Added.

(getOwnPropertyDescriptor):
(ownKeys):

  • test262/test/language/expressions/object/object-spread-proxy-no-excluded-keys.js: Copied from JSTests/test262/test/language/expressions/object/object-spread-proxy-ownkeys-returned-keys-order.js.

(getOwnPropertyDescriptor):
(ownKeys):

  • test262/test/language/expressions/object/object-spread-proxy-ownkeys-returned-keys-order.js:
  • test262/test/language/statements/class/constructor-inferred-observable-iteration.js: Removed.
  • test262/test/language/statements/class/subclass/default-constructor-spread-override.js:

(Array.prototype.Symbol.iterator):
(Base):

  • test262/test262-Revision.txt:
9:59 PM Changeset in webkit [273873] by commit-queue@webkit.org
  • 4 edits
    2 moves
    2 deletes in trunk/Source/WebCore

Remove RemoteCommandListenerIOS in favor of a common RemoteCommandListenerCocoa
https://bugs.webkit.org/show_bug.cgi?id=222342
rdar://problem/74773837

Patch by Jean-Yves Avenard <Jean-Yves Avenard> on 2021-03-03
Reviewed by Eric Carlson.

There is no change in behavior with this commit.

  • SourcesCocoa.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • platform/RemoteCommandListener.cpp:

(WebCore::RemoteCommandListener::resetCreationFunction):

  • platform/cocoa/RemoteCommandListenerCocoa.h: Renamed from Source/WebCore/platform/mac/RemoteCommandListenerMac.h.
  • platform/cocoa/RemoteCommandListenerCocoa.mm: Renamed from Source/WebCore/platform/mac/RemoteCommandListenerMac.mm.

(WebCore::RemoteCommandListenerCocoa::create):
(WebCore::RemoteCommandListenerCocoa::defaultCommands):
(WebCore::RemoteCommandListenerCocoa::updateSupportedCommands):
(WebCore::RemoteCommandListenerCocoa::RemoteCommandListenerCocoa):
(WebCore::RemoteCommandListenerCocoa::~RemoteCommandListenerCocoa):

  • platform/ios/RemoteCommandListenerIOS.h: Removed.
  • platform/ios/RemoteCommandListenerIOS.mm: Removed.
9:00 PM Changeset in webkit [273872] by commit-queue@webkit.org
  • 9 edits in trunk/Source

Limit HashTable entry size to 500 bytes
https://bugs.webkit.org/show_bug.cgi?id=222658

Patch by Alex Christensen <achristensen@webkit.org> on 2021-03-03
Reviewed by Yusuke Suzuki.

Source/WebCore:

Moving large structures inside HashTables is slower than just moving a pointer.
There is a point at which it becomes more efficient to add a separate allocation
rather than have gigantic HashTables that use all that memory for each empty slot
and use all those read and write operations to move when rehashing. I'm not sure
exactly where that point is, but I'm pretty sure it's less than 500 bytes. This
introduces a limit and removes the two largest HashTables in WebKit, replacing their
values with std::unique_ptr to save memory and time.

  • Modules/cache/DOMCacheEngine.h:
  • platform/network/NetworkLoadInformation.h:

Source/WebKit:

  • NetworkProcess/NetworkConnectionToWebProcess.h:

(WebKit::NetworkConnectionToWebProcess::getNetworkLoadInformationResponse):
(WebKit::NetworkConnectionToWebProcess::getNetworkLoadIntermediateInformation):
(WebKit::NetworkConnectionToWebProcess::takeNetworkLoadInformationMetrics):
(WebKit::NetworkConnectionToWebProcess::addNetworkLoadInformation):
(WebKit::NetworkConnectionToWebProcess::addNetworkLoadInformationMetrics):

  • NetworkProcess/cache/CacheStorageEngineCaches.cpp:

(WebKit::CacheStorage::Caches::writeRecord):
(WebKit::CacheStorage::Caches::readRecord):

  • NetworkProcess/cache/CacheStorageEngineCaches.h:

Source/WTF:

  • wtf/HashTable.h:

(WTF::KeyTraits>::inlineLookup):

8:35 PM Changeset in webkit [273871] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

[ Catalina wk1 ews ] media/remote-control-command-seek.html is a flaky timeout
https://bugs.webkit.org/show_bug.cgi?id=215325

Unreviewed test gardening.

  • platform/mac-wk1/TestExpectations: Update test expectations since EWS moved to Catalina.
8:19 PM Changeset in webkit [273870] by ysuzuki@apple.com
  • 2 edits in trunk/Source/WTF

[JSC] ENABLE(JIT_CAGE) requires HAVE(JIT_CAGE)
https://bugs.webkit.org/show_bug.cgi?id=222695

Reviewed by Saam Barati.

HAVE(JIT_CAGE) is internally defined. We use HAVE(JIT_CAGE) when defining ENABLE(JIT_CAGE).

  • wtf/PlatformEnable.h:
6:31 PM Changeset in webkit [273869] by Andres Gonzalez
  • 9 edits in trunk

Replace the multiple WebAccessibilityObjectWrapperIOS postXXXNotification methods with a single postNotification method.
https://bugs.webkit.org/show_bug.cgi?id=221707

Reviewed by Chris Fleizach.

Source/WebCore:

Instead of having a postXXXNotification method per notification in the
iOS WebAccessibilitObjectWrapper implementation, we now have a single
method that takes the name of the notification. This cleans up the
existing notification posting code and simplifies adding new notifications.

  • accessibility/AXLogger.cpp:

(WebCore::operator<<): Added a new notification constant AXPageScrolled.

  • accessibility/AXObjectCache.h:
  • accessibility/ios/AXObjectCacheIOS.mm:

(WebCore::AXObjectCache::notificationPlatformName):
Handles all notifications used on iOS.
(WebCore::AXObjectCache::postPlatformNotification):

  • accessibility/ios/WebAccessibilityObjectWrapperIOS.h:
  • accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:

(-[WebAccessibilityObjectWrapper accessibilityScroll:]):
Uses the helper AXObjectCache::notificationPlatformName to get page scrolled notification name.
(-[WebAccessibilityObjectWrapper postFocusChangeNotification]): Deleted.
(-[WebAccessibilityObjectWrapper postSelectedTextChangeNotification]): Deleted.
(-[WebAccessibilityObjectWrapper postLayoutChangeNotification]): Deleted.
(-[WebAccessibilityObjectWrapper postLiveRegionChangeNotification]): Deleted.
(-[WebAccessibilityObjectWrapper postLiveRegionCreatedNotification]): Deleted.
(-[WebAccessibilityObjectWrapper postLoadCompleteNotification]): Deleted.
(-[WebAccessibilityObjectWrapper postChildrenChangedNotification]): Deleted.
(-[WebAccessibilityObjectWrapper postInvalidStatusChangedNotification]): Deleted.
(-[WebAccessibilityObjectWrapper postValueChangedNotification]): Deleted.
(-[WebAccessibilityObjectWrapper postExpandedChangedNotification]): Deleted.
(-[WebAccessibilityObjectWrapper postScrollStatusChangeNotification]): Deleted.
(-[WebAccessibilityObjectWrapper postCurrentStateChangedNotification]): Deleted.

LayoutTests:

The name of the notification is now "AXPageScrolled". Adjusted the script
and the expected output accordingly.

  • accessibility/ios-simulator/scroll-in-overflow-div-expected.txt:
  • accessibility/ios-simulator/scroll-in-overflow-div.html:
6:13 PM Changeset in webkit [273868] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

Crash in removeSymbolElementsFromSubtree()
https://bugs.webkit.org/show_bug.cgi?id=222397

Patch by Julian Gonzalez <julian_a_gonzalez@apple.com> on 2021-03-03
Reviewed by Ryosuke Niwa.

Skip children in removeSymbolElementsFromSubtree(), so that
we don't see nodes that have been removed in disassociateAndRemoveClones.

Thanks to Darin Adler for the initial version of this patch
and Ryosuke Niwa for refinements.

  • svg/SVGUseElement.cpp:

(WebCore::removeSymbolElementsFromSubtree):

5:49 PM Changeset in webkit [273867] by Chris Dumez
  • 11 edits in trunk

Unreviewed, reverting r273851.

Caused some tests failures on macOS Big Sur

Reverted changeset:

"[macOS][WK2] Changing the system language does not update
navigator.language"
https://bugs.webkit.org/show_bug.cgi?id=222619
https://commits.webkit.org/r273851

5:48 PM Changeset in webkit [273866] by rniwa@webkit.org
  • 2 edits in trunk/Source/WebCore

Nulllptr crash in DeleteSelectionCommand::handleGeneralDelete()
https://bugs.webkit.org/show_bug.cgi?id=222681

Reviewed by Wenson Hsieh.

Skip the loop when m_downstreamEnd.isNull() or im_downstreamEnd.isOrphan() is true
to avoid dereferencing a nullptr.

No new tests since we don't have any reproduction for this crash,
and it's not obvious how we're getting into that state.

  • editing/DeleteSelectionCommand.cpp:

(WebCore::DeleteSelectionCommand::handleGeneralDelete):

5:34 PM Changeset in webkit [273865] by Devin Rousso
  • 38 edits
    2 moves
    1 add
    2 deletes in trunk

Web Inspector: RecordCanvasActionVariant causes a huge symbol to be created in WebCore
https://bugs.webkit.org/show_bug.cgi?id=222639
<rdar://problem/73728057>

Reviewed by Tim Horton and Brian Burg.

Source/JavaScriptCore:

  • inspector/protocol/Recording.json:

Drive-by: Add info about snapshot to the "description" of "actions" in "Frame".

Source/WebCore:

The only reason that RecordCanvasActionVariant exists is so that the generated IDL code
can pass all arguments at once to the function defined by CallTracingCallback. Instead,
change CallTracingCallback (which expects a static function on CallTracer) to be
CallTracer (which expects a class) so that more than one function can be used in the
generated IDL code (and so that not every usage has to be part of `CallTracer). These new
functions are:

  • processArgument, which is used to convert the argument to a more generic type
  • recordAction, which is basically what CallTracingCallback used to be

In the case of InspectorCanvasCallTracer (which is what recordCanvasAction used to be),
processArgument converts to a struct of JSON::Value and RecordingSwizzleType, which
used to happen way later in InspectorCanvas::buildAction (which is why there used to be
RecordCanvasActionVariant as there was no other good way of handling all the various
arguments of all the various functions). The only effect that this change has is that now
the deduplicated data in the Recording payload might have a different order, as
arguments are deduplicated before action names, but this shouldn't have any noticable effect
as the Web Inspector frontend handles the "unpacking" of the deduplicated data in the same
way (and the tests confirm it).

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateAttributeGetterBodyDefinition):
(GenerateAttributeSetterBodyDefinition):
(GenerateImplementationFunctionCall):
(GenerateCallTracer):

  • bindings/scripts/IDLAttributes.json:
  • bindings/scripts/test/TestCallTracer.idl:
  • bindings/scripts/test/JS/JSTestCallTracer.cpp:

Replace CallTracingCallback with CallTracer

  • inspector/InspectorCanvasCallTracer.h: Added.

(WebCore::InspectorCanvasCallTracer::recordAction):

  • inspector/InspectorCanvasCallTracer.cpp: Added.

(WebCore::enabledCanvasAgent):
(WebCore::InspectorCanvasCallTracer::recordAction):
(WebCore::InspectorCanvasCallTracer::processArgument):

  • bindings/js/CallTracer.h: Removed.
  • bindings/js/CallTracer.cpp: Removed.
  • inspector/InspectorInstrumentation.h:

(WebCore::InspectorInstrumentation::recordCanvasAction): Deleted.
(WebCore::InspectorInstrumentation::recordCanvasActionImpl): Deleted.

  • inspector/InspectorInstrumentation.cpp:

(WebCore::InspectorInstrumentation::recordCanvasActionImpl): Deleted.
Rather than piping through InspectorInstrumentation (which would require adding #include
for all the argument types in the .h), just pull out the InspectorCanvasAgent and use it
locally here.

  • inspector/InspectorCanvas.h:
  • inspector/InspectorCanvas.cpp:

(WebCore::InspectorCanvas::canvasChanged):
(WebCore::InspectorCanvas::resetRecordingData):
(WebCore::InspectorCanvas::processArgument):
(WebCore::InspectorCanvas::recordAction):
(WebCore::InspectorCanvas::valueIndexForData): Added.
(WebCore::InspectorCanvas::buildAction):

  • inspector/agents/InspectorCanvasAgent.h:
  • inspector/agents/InspectorCanvasAgent.cpp:

(WebCore::InspectorCanvasAgent::startRecording):
(WebCore::InspectorCanvasAgent::stopRecording):
(WebCore::InspectorCanvasAgent::didFinishRecordingCanvasFrame):
(WebCore::InspectorCanvasAgent::recordAction): Added.
(WebCore::InspectorCanvasAgent::recordCanvasAction): Deleted.
Create individual processArgument member function for each type used by the various canvas
contexts instead of having one giant WTF::switchOn for RecordCanvasActionVariant.

  • html/HTMLCanvasElement.idl:
  • html/canvas/CanvasRenderingContext2D.idl:
  • html/canvas/ImageBitmapRenderingContext.idl:
  • html/canvas/OffscreenCanvasRenderingContext2D.idl:
  • html/canvas/WebGL2RenderingContext.idl:
  • html/canvas/WebGLRenderingContext.idl:

Replace CallTracingCallback=recordCanvasAction with CallTracer=InspectorCanvasCallTracer.

  • html/CanvasBase.h:
  • html/CanvasBase.cpp:

(WebCore::CanvasBase::hasActiveInspectorCanvasCallTracer const): Added.
(WebCore::CanvasBase::callTracingActive const): Deleted.

  • html/HTMLCanvasElement.cpp:

(WebCore::HTMLCanvasElement::paint):

  • html/canvas/CanvasRenderingContext.h:

(WebCore::CanvasRenderingContext::hasActiveInspectorCanvasCallTracer const): Added.
(WebCore::CanvasRenderingContext::setHasActiveInspectorCanvasCallTracer): Added.
(WebCore::CanvasRenderingContext::callTracingActive const): Deleted.
(WebCore::CanvasRenderingContext::setCallTracingActive): Deleted.

  • html/canvas/WebGLRenderingContextBase.cpp:

(WebCore::WebGLRenderingContextBase::didComposite):
Replace callTracingActive with hasActiveInspectorCanvasCallTracer.

  • inspector/RecordingSwizzleType.h: Renamed from Source/WebCore/inspector/RecordingSwizzleTypes.h.

Drive-by: Rename RecordingSwizzleTypes to RecordingSwizzleType.

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • html/canvas/WebGL2RenderingContext.cpp:
  • html/canvas/WebGLRenderingContext.cpp:
  • loader/DocumentThreadableLoader.cpp:
  • loader/ImageLoader.cpp:
  • loader/TextTrackLoader.cpp:
  • page/Page.cpp:

Drive-by: unified sources include fixes

Source/WebInspectorUI:

  • UserInterface/Models/RecordingAction.js:

(WI.RecordingAction):
Don't use || for the fallback of _payloadSnapshot as it can be 0.

  • UserInterface/Models/Recording.js:

Drive-by: Rename RecordingSwizzleTypes to RecordingSwizzleType.

LayoutTests:

  • inspector/canvas/resources/recording-webgl2.js:
  • inspector/canvas/recording-webgl2-full-expected.txt:

Use an actual uniform name instead of a random test string.

5:19 PM Changeset in webkit [273864] by Russell Epstein
  • 1 copy in tags/Safari-611.1.21.0.3

Tag Safari-611.1.21.0.3.

5:00 PM Changeset in webkit [273863] by Alan Coon
  • 4 edits in branches/safari-612.1.5-branch/Source/WebCore

Cherry-pick r273839. rdar://problem/75009410

REGRESSION (r273154): Speedometer 2 is 1-2% regressed on iOS
https://bugs.webkit.org/show_bug.cgi?id=222663
<rdar://problem/74715929>

Reviewed by Ryosuke Niwa.

A 1-2% regression was observed in Speedometer 2 after enabling the iOS
Form Control Refresh (FCR). Traces indicated an increased amount of time
spent in style resolution. Note that currently the FCR styles are
appended to the base UA stylesheet at runtime, to apply the necessary
changes for the new appearance, while making it possible to toggle the
feature.

To fix, the FCR stylesheet is merged into the base UA stylesheet. This
avoids ruleset duplication, which made it more expensive to resolve
styles. To preserve the old appearance when the feature is runtime
disabled, the old styles are moved into a separate stylesheet, appended
at runtime.

The fix was verified as an equivalent progression using internal A/B
testing infrastructure.

Note that this solution means that disabling the FCR will result in a
Speedometer regression, due to ruleset duplication. However, this should
not be a concern since the feature is controlled by an internal switch,
is enabled by default, and is not intended to be disabled.

  • css/formControlsIOS.css:
  • css/html.css:
  • style/UserAgentStyle.cpp: (WebCore::Style::UserAgentStyle::ensureDefaultStyleSheetsForElement):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@273839 268f45cc-cd09-0410-ab3c-d52691b4dbfc

5:00 PM Changeset in webkit [273862] by Alan Coon
  • 4 edits
    2 adds in branches/safari-612.1.5-branch

Cherry-pick r273821. rdar://problem/75009461

REGRESSION (r266288): Web Inspector: ::marker shows on every element now
https://bugs.webkit.org/show_bug.cgi?id=222384

Reviewed by Devin Rousso.

Source/WebCore:

Test: inspector/css/getMatchedStylesForNodeMarkerPseudoId.html

Add filtering of the ::marker CSS rule for elements that are not list items, as they do no apply to the
element.

  • inspector/agents/InspectorCSSAgent.cpp: (WebCore::InspectorCSSAgent::getMatchedStylesForNode):
  • Added filtering for *::marker rules on non-display:list-item elements. (WebCore::InspectorCSSAgent::buildObjectForRule):
  • Drive-by refactoring to reduce code duplication.

LayoutTests:

Added test for the filtering of *::marker selector from the rule results of CSS.getMatchedStyleForNode on
elements that don't support ::marker.

  • inspector/css/getMatchedStylesForNode-expected.txt:
  • Updated expectations to account for the abscence of the ::marker rule on non-list elements.
  • inspector/css/getMatchedStylesForNodeMarkerPseudoId-expected.txt: Added.
  • inspector/css/getMatchedStylesForNodeMarkerPseudoId.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@273821 268f45cc-cd09-0410-ab3c-d52691b4dbfc

5:00 PM Changeset in webkit [273861] by Alan Coon
  • 4 edits
    2 adds in branches/safari-612.1.5-branch

Cherry-pick r273764. rdar://problem/75009398

The layout of SVGImage should force the layout for its clients
https://bugs.webkit.org/show_bug.cgi?id=221253
<rdar://problem/74138641>

Reviewed by Simon Fraser.

Source/WebCore:

Unlike the bitmap image, the intrinsic size of SVGImage can only be known
after running its layout. Because SVGImage can be used by multiple clients,
CachedImage maintains an SVGImageCache which maps a client to an
SVGImageForContainer. SVGImageForContainer is just a wrapper of SVGImage
with the intrinsic size of the client. Because we may set an entry for
the renderer in SVGImageCache early before running a layout for SVGImage
and because the renderer intrinsic size depends on the intrinsic size of
SVGImage, SVGImageForContainer may have an empty intrinsic size.

So basically it is a race condition: knowing the intrinsic size of the
SVGImage client depends on the intrinsic size of SVGImage itself. And the
intrinsic size of SVGImageForContainer depends on the intrinsic size of
the client. This may lead to not rendering the clients because their sizes
are empty. To fix this issue we need to force calculateBackgroundImageGeometry()
once we finish the layout of the SVGImage which happens after receiving all
its data and calling RenderBox::imageChanged().

Test: fast/css/background-svg-image-loading.html

  • loader/cache/CachedImage.cpp: (WebCore::CachedImage::finishLoading):
  • rendering/RenderBox.cpp: (WebCore::RenderBox::repaintLayerRectsForImage):

LayoutTests:

  • fast/css/background-svg-image-loading-expected.html: Added.
  • fast/css/background-svg-image-loading.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@273764 268f45cc-cd09-0410-ab3c-d52691b4dbfc

5:00 PM Changeset in webkit [273860] by Alan Coon
  • 2 edits in branches/safari-612.1.5-branch

Cherry-pick r273699. rdar://problem/75009467

[Win] Fix build failure
https://bugs.webkit.org/show_bug.cgi?id=222576
<rdar://problem/74590803>
Reviewed by Brent Fulgham.

It appears a recent change has unintentionally enabled WebInspectorUI on Apple Win. Address this by explicitly disabling it.

  • Source/cmake/OptionsAppleWin.cmake:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@273699 268f45cc-cd09-0410-ab3c-d52691b4dbfc

4:49 PM Changeset in webkit [273859] by Ryan Haddad
  • 9 edits in trunk/Source

Unreviewed, reverting r273832.

26 inspector tests failing a new assert added with this change

Reverted changeset:

"Limit HashTable entry size to 500 bytes"
https://bugs.webkit.org/show_bug.cgi?id=222658
https://commits.webkit.org/r273832

4:41 PM Changeset in webkit [273858] by Russell Epstein
  • 1 copy in tags/Safari-611.1.21.1.4

Tag Safari-611.1.21.1.4.

4:40 PM Changeset in webkit [273857] by Russell Epstein
  • 1 delete in tags/Safari-611.1.21.1.4

Delete tag.

4:39 PM Changeset in webkit [273856] by Russell Epstein
  • 8 edits in branches/safari-611.1.21.1-branch/Source

Versioning.

WebKit-7611.1.21.1.4

4:29 PM Changeset in webkit [273855] by Ruben Turcios
  • 1 copy in tags/Safari-611.1.21.1.4

Tag Safari-611.1.21.1.4.

4:15 PM Changeset in webkit [273854] by commit-queue@webkit.org
  • 7 edits
    1 add in trunk/Tools

Make LayoutTestFinder.find_tests/find_tests_by_path return List[Test]
https://bugs.webkit.org/show_bug.cgi?id=222662

Patch by Sam Sneddon <Sam Sneddon> on 2021-03-03
Reviewed by Jonathan Bedard.

This introduces a Test class, to later be able to migrate finding
expectations to LayoutTestFinder.

  • Scripts/open-layout-test:

(main):

  • Scripts/webkitpy/layout_tests/controllers/layout_test_finder.py:

(LayoutTestFinder.find_tests):
(LayoutTestFinder.find_tests_by_path):

  • Scripts/webkitpy/layout_tests/controllers/layout_test_finder_unittest.py:

(LayoutTestFinderTests.test_find_with_skipped_directories):

  • Scripts/webkitpy/layout_tests/controllers/manager.py:

(Manager.run):
(Manager.print_expectations):

  • Scripts/webkitpy/layout_tests/models/test.py: Added.

(Test):
(Test.init):
(Test.repr):
(Test.eq):

  • Scripts/webkitpy/layout_tests/models/test_input.py:

(TestInput):

  • Scripts/webkitpy/tool/commands/queries.py:

(PrintExpectations.execute):

3:54 PM Changeset in webkit [273853] by Peng Liu
  • 7 edits in trunk/LayoutTests

[GPUP] Two tests related to media element state are flaky when media in GPU Process is enabled
https://bugs.webkit.org/show_bug.cgi?id=221688

Reviewed by Jer Noble.

This patch fixes two flaky tests by updating the expected value of a media element's "networkState"
in a "loadstart" event handler.

A video/audio element's network state may have changed from LOADING to IDLE before the "loadstart"
event handler executes. That will happen when the media player notifies the element with a network
state change (by calling HTMLMediaElement::setNetworkState()) from LOADING to LOADED quickly.
The code snippet is below:

`
void HTMLMediaElement::setNetworkState(MediaPlayer::NetworkState state)
{

...
if (state == MediaPlayer::NetworkState::Loaded) {

if (m_networkState != NETWORK_IDLE)

changeNetworkStateFromLoadingToIdle();

m_completelyLoaded = true;

}

}
`

  • media/W3C/audio/networkState/networkState_during_loadstart-expected.txt:
  • media/W3C/audio/networkState/networkState_during_loadstart.html:
  • media/W3C/video/networkState/networkState_during_loadstart-expected.txt:
  • media/W3C/video/networkState/networkState_during_loadstart.html:
  • platform/mac/TestExpectations:
  • platform/wk2/TestExpectations:
3:46 PM Changeset in webkit [273852] by commit-queue@webkit.org
  • 2 edits in trunk/Tools

Send console.log() etc. to stdout in MiniBrowser on macOS
https://bugs.webkit.org/show_bug.cgi?id=222629

Patch by Cameron McCormack <Cameron McCormack> on 2021-03-03
Reviewed by Tim Horton.

  • MiniBrowser/mac/AppDelegate.m:

(-[BrowserAppDelegate defaultConfiguration]):

3:46 PM Changeset in webkit [273851] by Chris Dumez
  • 11 edits in trunk

[macOS][WK2] Changing the system language does not update navigator.language
https://bugs.webkit.org/show_bug.cgi?id=222619

Reviewed by Per Arne Vollan.

Source/WebKit:

  • Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceMain.mm:

(WebKit::setAppleLanguagesPreference):

  • When ENABLE(CFPREFS_DIRECT_MODE), we don't need to set the AppleLanguages

in a volatile domain. This does not change behavior but I made this change
so that I don't need to set AppleLanguages in the volatile domain in
WebProcessCocoa when the preference changes.

  • Also fix a memory leak for newArguments.
  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::WebProcess::platformInitializeWebProcess):
If CFPREFS_DIRECT_MODE is not enabled, we need to listen for AppleLanguagePreferencesChangedNotification
inside the WebProcess. This used to happen implicitly inside WTF::platformUserPreferredLanguages() but
it is now explicit since we don't want/need it when using CFPREFS_DIRECT_MODE.

(WebKit::setPreferenceValue):

  • Call CFPreferencesSetAppValue() instead of CFPreferencesSetValue(). Without this change

trying to set AppleLanguages here would have no effect and CFLocaleCopyPreferredLanguages()
would keep returning outdated languages.

  • Call WTF::languageDidChange() when the AppleLanguages preference gets updated so that language change listeners get notified of the language change (e.g. we fire a languagechange event at the Window).

Source/WebKitLegacy/mac:

We need to listen for AppleLanguagePreferencesChangedNotification on mac WK1.
This used to happen implicitly inside WTF::platformUserPreferredLanguages() but
it is now explicit since we don't want/need it when using CFPREFS_DIRECT_MODE in WK2.

  • WebView/WebView.mm:

(-[WebView _commonInitializationWithFrameName:groupName:]):

Source/WTF:

Update WTF::languageDidChange() to clear preferredLanguages() on Cocoa platforms
so that we get updated values from the system the next time
platformUserPreferredLanguages() is called.

platformUserPreferredLanguages() used to implicitly register a AppleLanguagePreferencesChangedNotification
listener. We've now made this registering opt-in by moving it to a separate
listenForLanguageChangeNotifications() function. This function is getting called
on Mac WK1 and WK2 when CFPREFS_DIRECT_MODE is disabled (legacy).
When CFPREFS_DIRECT_MODE is enabled in WK2, we don't want/need to listen for this
notification because the AppleLanguages preference gets pushed by the UIProcess
down to the WebProcesses. Even though we could listen for this notification,
the WebProcess would not have the latest AppleLanguages preference when receiving
the notification. This would cause us to fire the languagechange event at the
Window too early and navigator.language would keep returning the old language.
For WK2 with CFPREFS_DIRECT_MODE enabled, we now explicitly call
WTF::languageDidChange() when the "AppleLanguages" preference gets sync'd from
the UIProcess instead.

  • wtf/Language.cpp:

(WTF::languageDidChange):
(WTF::platformLanguageDidChange):

  • wtf/Language.h:
  • wtf/cf/LanguageCF.cpp:

(WTF::languagePreferencesDidChange):
(WTF::platformLanguageDidChange):
(WTF::listenForLanguageChangeNotifications):
(WTF::platformUserPreferredLanguages):

Tools:

Add API test coverage.

  • TestWebKitAPI/Tests/WebKit/OverrideAppleLanguagesPreference.mm:

(TEST):

3:38 PM Changeset in webkit [273850] by Truitt Savell
  • 2 edits in trunk/LayoutTests

[BigSur WK1 Release] media/video-aspect-ratio.html is a flakey timeout
https://bugs.webkit.org/show_bug.cgi?id=222693

Unreviewed test gardening.

Patch by Amir Mark Jr <Amir Mark Jr.> on 2021-03-03

  • platform/mac-wk1/TestExpectations:
3:31 PM Changeset in webkit [273849] by ysuzuki@apple.com
  • 2 edits in trunk/Source/WTF

[WTF] Add System.framework PrivateHeaders to header path of WTF
https://bugs.webkit.org/show_bug.cgi?id=222688

Reviewed by Tim Horton.

The other non-third-party components excluding WTF have System.framework PrivateHeaders in their header search path.
This causes the problem that we cannot use some system headers (e.g. <machine/cpu_capabilities.h>) in WTF while it is
usable in JavaScriptCore and the other components. This patch adds it as the other components did.

  • Configurations/Base.xcconfig:
3:07 PM Changeset in webkit [273848] by Chris Dumez
  • 17 edits in trunk

Use adoptNS() right away after calling [obj copy] / [obj mutableCopy]
https://bugs.webkit.org/show_bug.cgi?id=222634

Reviewed by Darin Adler.

Use adoptNS() right away after calling [obj copy] / [obj mutableCopy] to minimize the chance of leaks.

Source/WebCore:

  • editing/cocoa/HTMLConverter.mm:

(defaultParagraphStyle):

  • platform/cocoa/SystemVersion.mm:

(WebCore::createSystemMarketingVersion):
(WebCore::systemMarketingVersion):

Source/WebKit:

  • Shared/ApplePay/ApplePayPaymentSetupFeatures.mm:

(WebKit::PaymentSetupFeatures::decode):

  • Shared/ApplePay/PaymentSetupConfiguration.mm:

(WebKit::PaymentSetupConfiguration::decode):

  • Shared/ApplePay/cocoa/PaymentSetupConfiguration.mm:

(WebKitAdditions::PaymentSetupConfiguration::decode):

  • UIProcess/Launcher/mac/ProcessLauncherMac.mm:

(WebKit::systemDirectoryPath):

  • UIProcess/mac/ServicesController.mm:

(WebKit::ServicesController::refreshExistingServices):

  • UIProcess/mac/WebPageProxyMac.mm:

(WebKit::temporaryPDFDirectoryPath):

Source/WebKitLegacy/mac:

  • Misc/WebNSPasteboardExtras.mm:

(_writableTypesForImageWithArchive):

  • WebCoreSupport/WebApplicationCache.mm:

(overrideBundleIdentifier):
(+[WebApplicationCache initializeWithBundleIdentifier:]):
(applicationCacheBundleIdentifier):

  • WebView/WebPreferences.mm:

(classIBCreatorID):
(+[WebPreferences _setIBCreatorID:]):
(+[WebPreferences _IBCreatorID]):

Tools:

  • TestWebKitAPI/Tests/WebKit/mac/ContextMenuMouseEvents.mm:

(TestWebKitAPI::runTest):

  • TestWebKitAPI/Tests/WebKitCocoa/UserContentController.mm:

(TEST):

3:00 PM Changeset in webkit [273847] by commit-queue@webkit.org
  • 5 edits in trunk/Source/WebInspectorUI

Web Inspector: Refine CSS Grid overlay options
https://bugs.webkit.org/show_bug.cgi?id=222428
<rdar://problem/74751569>

Patch by Razvan Caliman <Razvan Caliman> on 2021-03-03
Reviewed by BJ Burg.

Move CSS Grid overlay settings above node list, simplify labels, reorder and set default values.

  • Localizations/en.lproj/localizedStrings.js:
  • UserInterface/Base/Setting.js:
  • UserInterface/Views/CSSGridSection.js:

(WI.CSSGridSection.prototype.initialLayout):

  • UserInterface/Views/LayoutDetailsSidebarPanel.css:

(.details-section.layout-css-grid.collapsed > .content):
Drive-by: Fix a bug which prevented the contents from being hidden when the section is collapsed.

3:00 PM Changeset in webkit [273846] by Caio Lima
  • 3 edits
    1 add in trunk

[ESNext] Private methods can't be named as '#constructor'
https://bugs.webkit.org/show_bug.cgi?id=222680

Reviewed by Yusuke Suzuki.

JSTests:

  • stress/private-method-and-field-named-constructor.js: Added.

Source/JavaScriptCore:

It's a SyntaxError when we try to use #constructor as private name
for methods, accessors, and fields. This patch is fixing such bug for
methods and accessors.

  • parser/Parser.cpp:

(JSC::Parser<LexerType>::parseClass):
(JSC::Parser<LexerType>::parseGetterSetter):

2:57 PM Changeset in webkit [273845] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] Enable simplified vertical alignment for non-empty inline boxes
https://bugs.webkit.org/show_bug.cgi?id=222666

Reviewed by Antti Koivisto.

This patch enables the simplified vertical alignment for cases when the line has non-stretching, baseline aligned non-empty inline boxes
even when the inline box spans multiple lines.
e.g.
<div><span>text content</span></div>

  • layout/inlineformatting/InlineFormattingContextGeometry.cpp:

(WebCore::Layout::LineBoxBuilder::constructAndAlignInlineLevelBoxes):
(WebCore::Layout::LineBoxBuilder::SimplifiedVerticalAlignment::canUseSimplifiedAlignment):

2:55 PM Changeset in webkit [273844] by commit-queue@webkit.org
  • 3 edits in trunk/Tools

Move LayoutTestFinder.skip_tests to Manager._skip_tests
https://bugs.webkit.org/show_bug.cgi?id=222661

Patch by Sam Sneddon <Sam Sneddon> on 2021-03-03
Reviewed by Jonathan Bedard.

This has nothing to do with finding tests, and everything to do about
test selection depending on the CLI.

Additionally, this removes the unused LayoutTestFinder.skip_tests
all_tests_list argument.

  • Scripts/webkitpy/layout_tests/controllers/layout_test_finder.py:

(LayoutTestFinder._skip_tests):

  • Scripts/webkitpy/layout_tests/controllers/manager.py:

(Manager._skip_tests):
(Manager._prepare_lists):

2:39 PM Changeset in webkit [273843] by commit-queue@webkit.org
  • 3 edits
    2 deletes in trunk

Unreviewed, reverting r273727.
https://bugs.webkit.org/show_bug.cgi?id=222689

Landed broken test

Reverted changeset:

"Null check platformData when decoding"
https://bugs.webkit.org/show_bug.cgi?id=221442
https://trac.webkit.org/changeset/273727

2:37 PM Changeset in webkit [273842] by Chris Dumez
  • 2 edits in trunk/Source/WebCore

Crash under SubresourceLoader::notifyDone()
https://bugs.webkit.org/show_bug.cgi?id=222683
<rdar://70342402>

Reviewed by Geoffrey Garen.

We were crashing doing a null-dereference of m_documentLoader under
SubresourceLoader::notifyDone(). This adds null checks for m_documentLoader
similarly to what is already done elsewhere in ResourceLoader.

No new tests, I do not know how to reproduce this.

  • loader/SubresourceLoader.cpp:

(WebCore::SubresourceLoader::notifyDone):

2:33 PM WebKitGTK/2.32.x edited by Michael Catanzaro
(diff)
2:23 PM Changeset in webkit [273841] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WTF

std::is_literal_type causes -Wdeprecated-declarations warning with GCC 11
https://bugs.webkit.org/show_bug.cgi?id=220662
<rdar://problem/73509470>

Patch by Michael Catanzaro <Michael Catanzaro> on 2021-03-03
Reviewed by Darin Adler.

Ignore the warning. It would be better to not use the deprecated std::is_literal_type, but
this works for now.

  • wtf/Variant.h:
2:23 PM Changeset in webkit [273840] by Robert Jenner
  • 2 edits in trunk/LayoutTests

[ macOS Wk2 ] inspector/model/auditTestCase.html is a flakey timeout
https://bugs.webkit.org/show_bug.cgi?id=222677

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations: Updating test expectations to Pass Timeout until test is fixed.
2:16 PM WebKitGTK/2.32.x edited by Michael Catanzaro
(diff)
2:04 PM Changeset in webkit [273839] by Aditya Keerthi
  • 4 edits in trunk/Source/WebCore

REGRESSION (r273154): Speedometer 2 is 1-2% regressed on iOS
https://bugs.webkit.org/show_bug.cgi?id=222663
<rdar://problem/74715929>

Reviewed by Ryosuke Niwa.

A 1-2% regression was observed in Speedometer 2 after enabling the iOS
Form Control Refresh (FCR). Traces indicated an increased amount of time
spent in style resolution. Note that currently the FCR styles are
appended to the base UA stylesheet at runtime, to apply the necessary
changes for the new appearance, while making it possible to toggle the
feature.

To fix, the FCR stylesheet is merged into the base UA stylesheet. This
avoids ruleset duplication, which made it more expensive to resolve
styles. To preserve the old appearance when the feature is runtime
disabled, the old styles are moved into a separate stylesheet, appended
at runtime.

The fix was verified as an equivalent progression using internal A/B
testing infrastructure.

Note that this solution means that disabling the FCR will result in a
Speedometer regression, due to ruleset duplication. However, this should
not be a concern since the feature is controlled by an internal switch,
is enabled by default, and is not intended to be disabled.

  • css/formControlsIOS.css:
  • css/html.css:
  • style/UserAgentStyle.cpp:

(WebCore::Style::UserAgentStyle::ensureDefaultStyleSheetsForElement):

2:00 PM Changeset in webkit [273838] by aakash_jain@apple.com
  • 2 edits in trunk/Tools

[ews] Add python 3 support - part 4
https://bugs.webkit.org/show_bug.cgi?id=222672

Reviewed by Jonathan Bedard.

  • CISupport/ews-build/events.py:

(JSONProducer): Use implementer (python 3 compatible) instead of implements.
(JSONProducer.init): Encode data as utf-8 explicitly.
(Events):
(Events.sendData):

1:56 PM Changeset in webkit [273837] by Robert Jenner
  • 2 edits in trunk/Tools

Adding myself as a committer in the contributors file.
N/A

N/A

  • Scripts/webkitpy/common/config/contributors.json: Added myself as a committer.
1:29 PM Changeset in webkit [273836] by commit-queue@webkit.org
  • 26 edits in trunk

Unreviewed, reverting r273814.
https://bugs.webkit.org/show_bug.cgi?id=222676

Unresolved types in JavaScriptCore-4.0.gir

Reverted changeset:

"[CMake] JavaScriptCore GLib headers should be copies"
https://bugs.webkit.org/show_bug.cgi?id=222625
https://trac.webkit.org/changeset/273814

1:23 PM Changeset in webkit [273835] by commit-queue@webkit.org
  • 3 edits in trunk/Tools

Remove LayoutTestFinder.touched_tests, which is now dead code
https://bugs.webkit.org/show_bug.cgi?id=222660

Patch by Sam Sneddon <Sam Sneddon> on 2021-03-03
Reviewed by Jonathan Bedard.

  • Scripts/webkitpy/layout_tests/controllers/layout_test_finder.py:

(LayoutTestFinder.find_touched_tests): Removed.

  • Scripts/webkitpy/layout_tests/controllers/layout_test_finder_unittest.py:

Remove related tests.

1:05 PM Changeset in webkit [273834] by Jonathan Bedard
  • 6 edits in trunk/Tools

[resultsdbpy] Make testing compatible with Python 3.8
https://bugs.webkit.org/show_bug.cgi?id=222678
<rdar://problem/74997936>

Rubber-stamped by Aakash Jain.

  • Scripts/libraries/resultsdbpy/resultsdbpy/init.py: Bump version.
  • Scripts/libraries/resultsdbpy/resultsdbpy/flask_support/flask_test_context.py:

(FlaskTestContext):
(FlaskTestContext.start_webserver): Make function pickle able.
(FlaskTestContext.init): Pass class to owning webserver setup.
(FlaskTestContext.enter):

  • Scripts/libraries/resultsdbpy/resultsdbpy/flask_support/flask_testcase.py:

(FlaskTestCase.run_with_real_webserver.decorator.real_method):

  • Scripts/libraries/resultsdbpy/resultsdbpy/model/cassandra_context.py:

(filter_for_argument): Style fix.

  • Scripts/libraries/resultsdbpy/setup.py: Bump version.
1:04 PM Changeset in webkit [273833] by timothy_horton@apple.com
  • 13 edits
    2 adds
    2 deletes in trunk/Source

Modernize WebKit2 PDFKit softlinking
https://bugs.webkit.org/show_bug.cgi?id=222643

Reviewed by Alex Christensen.

Source/WebKit:

WebKit2 has long had an unusual way of softlinking PDFKit, using NSBundle.
It has caused much trouble in the past, because it means that running
WebKit against a custom PDFKit requires either installing it into
the system, or changing the hardcoded path.

Instead of this, just use the normal softlinking macros that the rest
of WebKit uses.

  • Shared/Cocoa/PDFKitSoftLink.h: Added.
  • Shared/Cocoa/PDFKitSoftLink.mm: Added.
  • Shared/mac/PDFKitImports.h: Removed.
  • Shared/mac/PDFKitImports.mm: Removed.
  • SourcesCocoa.txt:
  • UIProcess/mac/WKPrintingView.mm:

(-[WKPrintingView _drawPDFDocument:page:atPoint:]):
(-[WKPrintingView drawRect:]):

  • WebKit.xcodeproj/project.pbxproj:
  • WebProcess/Plugins/PDF/PDFPlugin.h:
  • WebProcess/Plugins/PDF/PDFPlugin.mm:

(WebKit::PDFPlugin::PDFPlugin):
(WebKit::PDFPlugin::receivedNonLinearizedPDFSentinel):
(WebKit::PDFPlugin::threadEntry):
(WebKit::PDFPlugin::documentDataDidFinishLoading):
(WebKit::PDFPlugin::setActiveAnnotation):
(WebKit::PDFPlugin::nextMatchForString):
(WebKit:: const):

  • WebProcess/Plugins/PDF/PDFPluginAnnotation.mm:

(WebKit::PDFPluginAnnotation::create):

  • WebProcess/Plugins/PDF/PDFPluginChoiceAnnotation.mm:
  • WebProcess/Plugins/PDF/PDFPluginPasswordField.mm:
  • WebProcess/Plugins/PDF/PDFPluginTextAnnotation.mm:
  • WebProcess/WebPage/mac/WebPageMac.mm:

(WebKit::WebPage::shouldUsePDFPlugin const):
(WebKit::drawPDFPage):

Source/WTF:

  • wtf/PlatformHave.h:
12:54 PM Changeset in webkit [273832] by commit-queue@webkit.org
  • 9 edits in trunk/Source

Limit HashTable entry size to 500 bytes
https://bugs.webkit.org/show_bug.cgi?id=222658

Patch by Alex Christensen <achristensen@webkit.org> on 2021-03-03
Reviewed by Yusuke Suzuki.

Source/WebCore:

Moving large structures inside HashTables is slower than just moving a pointer.
There is a point at which it becomes more efficient to add a separate allocation
rather than have gigantic HashTables that use all that memory for each empty slot
and use all those read and write operations to move when rehashing. I'm not sure
exactly where that point is, but I'm pretty sure it's less than 500 bytes. This
introduces a limit and removes the two largest HashTables in WebKit, replacing their
values with std::unique_ptr to save memory and time.

  • Modules/cache/DOMCacheEngine.h:
  • platform/network/NetworkLoadInformation.h:

Source/WebKit:

  • NetworkProcess/NetworkConnectionToWebProcess.h:

(WebKit::NetworkConnectionToWebProcess::getNetworkLoadInformationResponse):
(WebKit::NetworkConnectionToWebProcess::getNetworkLoadIntermediateInformation):
(WebKit::NetworkConnectionToWebProcess::takeNetworkLoadInformationMetrics):
(WebKit::NetworkConnectionToWebProcess::addNetworkLoadInformation):
(WebKit::NetworkConnectionToWebProcess::addNetworkLoadInformationMetrics):

  • NetworkProcess/cache/CacheStorageEngineCaches.cpp:

(WebKit::CacheStorage::Caches::writeRecord):
(WebKit::CacheStorage::Caches::readRecord):

  • NetworkProcess/cache/CacheStorageEngineCaches.h:

Source/WTF:

  • wtf/HashTable.h:

(WTF::KeyTraits>::inlineLookup):

12:19 PM Changeset in webkit [273831] by Ruben Turcios
  • 4 edits
    2 adds in branches/safari-611.1.21.1-branch

Cherry-pick r273764. rdar://problem/74992878

The layout of SVGImage should force the layout for its clients
https://bugs.webkit.org/show_bug.cgi?id=221253
<rdar://problem/74138641>

Reviewed by Simon Fraser.

Source/WebCore:

Unlike the bitmap image, the intrinsic size of SVGImage can only be known
after running its layout. Because SVGImage can be used by multiple clients,
CachedImage maintains an SVGImageCache which maps a client to an
SVGImageForContainer. SVGImageForContainer is just a wrapper of SVGImage
with the intrinsic size of the client. Because we may set an entry for
the renderer in SVGImageCache early before running a layout for SVGImage
and because the renderer intrinsic size depends on the intrinsic size of
SVGImage, SVGImageForContainer may have an empty intrinsic size.

So basically it is a race condition: knowing the intrinsic size of the
SVGImage client depends on the intrinsic size of SVGImage itself. And the
intrinsic size of SVGImageForContainer depends on the intrinsic size of
the client. This may lead to not rendering the clients because their sizes
are empty. To fix this issue we need to force calculateBackgroundImageGeometry()
once we finish the layout of the SVGImage which happens after receiving all
its data and calling RenderBox::imageChanged().

Test: fast/css/background-svg-image-loading.html

  • loader/cache/CachedImage.cpp: (WebCore::CachedImage::finishLoading):
  • rendering/RenderBox.cpp: (WebCore::RenderBox::repaintLayerRectsForImage):

LayoutTests:

  • fast/css/background-svg-image-loading-expected.html: Added.
  • fast/css/background-svg-image-loading.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@273764 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:18 PM Changeset in webkit [273830] by Ruben Turcios
  • 2 edits in branches/safari-611.1.21.1-branch

Cherry-pick r273699. rdar://problem/74992920

[Win] Fix build failure
https://bugs.webkit.org/show_bug.cgi?id=222576
<rdar://problem/74590803>
Reviewed by Brent Fulgham.

It appears a recent change has unintentionally enabled WebInspectorUI on Apple Win. Address this by explicitly disabling it.

  • Source/cmake/OptionsAppleWin.cmake:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@273699 268f45cc-cd09-0410-ab3c-d52691b4dbfc

11:42 AM Changeset in webkit [273829] by Truitt Savell
  • 2 edits in trunk/LayoutTests

imported/w3c/web-platform-tests/webaudio/the-audio-api/the-mediaelementaudiosourcenode-interface/mediaElementAudioSourceToScriptProcessorTest.html fails for mac wk1 debug
https://bugs.webkit.org/show_bug.cgi?id=221819

Unreviewed test gardening.

  • platform/mac-wk1/TestExpectations:
11:10 AM Changeset in webkit [273828] by Chris Gambrell
  • 3 edits
    1 add
    1 delete in trunk/LayoutTests

[LayoutTests] Convert http/tests/dom convert PHP to Python
https://bugs.webkit.org/show_bug.cgi?id=222656
<rdar://problem/74984539>

Reviewed by Jonathan Bedard.

  • http/tests/dom/document-contentType-xhr.html:
  • http/tests/dom/document-contentType.html:
  • http/tests/dom/resources/send-mime-type.php: Removed.
  • http/tests/dom/resources/send-mime-type.py: Added.
11:08 AM Changeset in webkit [273827] by Ruben Turcios
  • 8 edits in branches/safari-611.1.21.0-branch/Source

Versioning.

WebKit-7611.1.21.0.3

10:54 AM Changeset in webkit [273826] by Megan Gardner
  • 26 edits in trunk/Source

Preserve information about the origin of the app highlight request
https://bugs.webkit.org/show_bug.cgi?id=222223

Reviewed by Wenson Hsieh.

Source/WebCore:

  • Modules/highlight/AppHighlight.h:

(WebCore::AppHighlight::encode const):
(WebCore::AppHighlight::decode):

  • Modules/highlight/AppHighlightStorage.cpp:

(WebCore::AppHighlightStorage::storeAppHighlight):

  • Modules/highlight/AppHighlightStorage.h:
  • loader/EmptyClients.cpp:

(WebCore::EmptyChromeClient::storeAppHighlight const):

  • loader/EmptyClients.h:
  • page/Chrome.cpp:

(WebCore::Chrome::storeAppHighlight const):

  • page/Chrome.h:
  • page/ChromeClient.h:

Source/WebKit:

  • Scripts/webkit/messages.py:
  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _storeAppHighlight:]):
(-[WKWebView _addAppHighlight]):

  • UIProcess/API/Cocoa/_WKAppHighlightDelegate.h:
  • UIProcess/Cocoa/WebPageProxyCocoa.mm:

(WebKit::WebPageProxy::createAppHighlightInSelectedRange):

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::contextMenuItemSelected):

  • UIProcess/WebPageProxy.h:
  • UIProcess/ios/WKContentViewInteraction.mm:

(-[WKContentView createHighlightInCurrentGroupWithRange:]):
(-[WKContentView createHighlightInNewGroupWithRange:]):

  • WebKit.xcodeproj/project.pbxproj:
  • WebProcess/WebCoreSupport/WebChromeClient.cpp:

(WebKit::WebChromeClient::storeAppHighlight const):

  • WebProcess/WebCoreSupport/WebChromeClient.h:
  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::createAppHighlightInSelectedRange):

  • WebProcess/WebPage/WebPage.h:

(WebKit::WebPage::highlightIsNewGroup const):
(WebKit::WebPage::highlightRequestOriginatedInApp const):

  • WebProcess/WebPage/WebPage.messages.in:

Source/WebKitLegacy/mac:

  • WebCoreSupport/WebChromeClient.h:
  • WebCoreSupport/WebChromeClient.mm:

(WebChromeClient::storeAppHighlight const):

10:47 AM Changeset in webkit [273825] by svillar@igalia.com
  • 19 edits
    23 adds
    12 deletes in trunk/LayoutTests

[css-flexbox] Import latest WPT tests
https://bugs.webkit.org/show_bug.cgi?id=222651

Reviewed by Rob Buis.

LayoutTests/imported/w3c:

Synced flex tests to 5b5efcee.

  • resources/resource-files.json:
  • web-platform-tests/css/css-flexbox/canvas-contain-size-expected.html: Added.
  • web-platform-tests/css/css-flexbox/canvas-contain-size.html: Added.
  • web-platform-tests/css/css-flexbox/css-flexbox-column-expected.html: Removed.
  • web-platform-tests/css/css-flexbox/css-flexbox-column-reverse-expected.html: Removed.
  • web-platform-tests/css/css-flexbox/css-flexbox-column-reverse-wrap-expected.html: Removed.
  • web-platform-tests/css/css-flexbox/css-flexbox-column-reverse-wrap-reverse-expected.html: Removed.
  • web-platform-tests/css/css-flexbox/css-flexbox-column-reverse-wrap-reverse.html: Removed.
  • web-platform-tests/css/css-flexbox/css-flexbox-column-reverse-wrap.html: Removed.
  • web-platform-tests/css/css-flexbox/css-flexbox-column-reverse.html: Removed.
  • web-platform-tests/css/css-flexbox/css-flexbox-column-wrap-expected.html: Removed.
  • web-platform-tests/css/css-flexbox/css-flexbox-column-wrap-reverse-expected.html: Removed.
  • web-platform-tests/css/css-flexbox/css-flexbox-column-wrap-reverse.html: Removed.
  • web-platform-tests/css/css-flexbox/css-flexbox-column-wrap.html: Removed.
  • web-platform-tests/css/css-flexbox/css-flexbox-column.html: Removed.
  • web-platform-tests/css/css-flexbox/flexbox-basic-canvas-vert-001-expected.xhtml:
  • web-platform-tests/css/css-flexbox/flexbox-basic-canvas-vert-001.xhtml:
  • web-platform-tests/css/css-flexbox/flexbox-basic-canvas-vert-001v-expected.xhtml:
  • web-platform-tests/css/css-flexbox/flexbox-basic-canvas-vert-001v.xhtml:
  • web-platform-tests/css/css-flexbox/flexbox-basic-iframe-vert-001-expected.xhtml:
  • web-platform-tests/css/css-flexbox/flexbox-basic-iframe-vert-001.xhtml:
  • web-platform-tests/css/css-flexbox/flexbox-basic-img-vert-001-expected.xhtml:
  • web-platform-tests/css/css-flexbox/flexbox-basic-img-vert-001.xhtml:
  • web-platform-tests/css/css-flexbox/flexbox-basic-textarea-vert-001-expected.xhtml:
  • web-platform-tests/css/css-flexbox/flexbox-basic-textarea-vert-001.xhtml:
  • web-platform-tests/css/css-flexbox/flexbox-basic-video-vert-001-expected.xhtml:
  • web-platform-tests/css/css-flexbox/flexbox-basic-video-vert-001.xhtml:
  • web-platform-tests/css/css-flexbox/frameset-crash.html: Added.
  • web-platform-tests/css/css-flexbox/table-as-item-inflexible-in-column-1-expected.html: Added.
  • web-platform-tests/css/css-flexbox/table-as-item-inflexible-in-column-1.html: Added.
  • web-platform-tests/css/css-flexbox/table-as-item-inflexible-in-column-2-expected.html: Added.
  • web-platform-tests/css/css-flexbox/table-as-item-inflexible-in-column-2.html: Added.
  • web-platform-tests/css/css-flexbox/table-as-item-inflexible-in-row-1-expected.html: Added.
  • web-platform-tests/css/css-flexbox/table-as-item-inflexible-in-row-1.html: Added.
  • web-platform-tests/css/css-flexbox/table-as-item-inflexible-in-row-2-expected.html: Added.
  • web-platform-tests/css/css-flexbox/table-as-item-inflexible-in-row-2.html: Added.
  • web-platform-tests/css/css-flexbox/table-as-item-narrow-content-2-expected.html: Added.
  • web-platform-tests/css/css-flexbox/table-as-item-narrow-content-2.html: Added.
  • web-platform-tests/css/css-flexbox/table-as-item-specified-height-expected.html: Added.
  • web-platform-tests/css/css-flexbox/table-as-item-specified-height.html: Added.
  • web-platform-tests/css/css-flexbox/table-as-item-specified-width.html:
  • web-platform-tests/css/css-flexbox/table-as-item-stretch-cross-size-2-expected.xht: Added.
  • web-platform-tests/css/css-flexbox/table-as-item-stretch-cross-size-2.html: Added.
  • web-platform-tests/css/css-flexbox/table-as-item-stretch-cross-size-3-expected.xht: Added.
  • web-platform-tests/css/css-flexbox/table-as-item-stretch-cross-size-3.html: Added.
  • web-platform-tests/css/css-flexbox/table-item-flex-percentage-min-width-expected.html: Added.
  • web-platform-tests/css/css-flexbox/table-item-flex-percentage-min-width.html: Added.
  • web-platform-tests/css/css-flexbox/w3c-import.log:

LayoutTests:

Imported latest changes in the test suite.

  • TestExpectations:
  • imported/w3c/web-platform-tests/css/css-flexbox/frameset-crash-expected.txt: Added.
  • platform/ios/imported/w3c/web-platform-tests/css/css-flexbox/frameset-crash-expected.txt: Added.
10:37 AM Changeset in webkit [273824] by dino@apple.com
  • 1 edit in trunk/Source/ThirdParty/ANGLE/ChangeLog

Add bug link to previous commit

10:33 AM Changeset in webkit [273823] by dino@apple.com
  • 3 edits in trunk/Source/ThirdParty/ANGLE

Support Depth24_Stencil8 simulation in the MTLSimulator

Patch by Kyle Piddington <Kyle Piddington> on 2021-03-03
Reviewed by Dean Jackson.

Fixes the following tests:
fast/canvas/webgl/context-creation-attributes.html
fast/canvas/webgl/webgl-depth-texture.html
webgl/1.0.3/conformance/misc/webgl-specific.html
webgl/1.0.3/conformance/renderbuffers/framebuffer-object-attachment.html

  • src/libANGLE/renderer/metal/mtl_format_map.json:
  • src/libANGLE/renderer/metal/mtl_format_table_autogen.mm:

(rx::mtl::Format::init):

10:11 AM Changeset in webkit [273822] by Ryan Haddad
  • 2 edits in trunk/Source/WebCore

Unreviewed, reverting r273809.

Caused assertion failure on debug WK2 bots

Reverted changeset:

"Crash in removeSymbolElementsFromSubtree()"
https://bugs.webkit.org/show_bug.cgi?id=222397
https://commits.webkit.org/r273809

9:59 AM Changeset in webkit [273821] by Patrick Angle
  • 4 edits
    2 adds in trunk

REGRESSION (r266288): Web Inspector: ::marker shows on every element now
https://bugs.webkit.org/show_bug.cgi?id=222384

Reviewed by Devin Rousso.

Source/WebCore:

Test: inspector/css/getMatchedStylesForNodeMarkerPseudoId.html

Add filtering of the ::marker CSS rule for elements that are not list items, as they do no apply to the
element.

  • inspector/agents/InspectorCSSAgent.cpp:

(WebCore::InspectorCSSAgent::getMatchedStylesForNode):

  • Added filtering for *::marker rules on non-display:list-item elements.

(WebCore::InspectorCSSAgent::buildObjectForRule):

  • Drive-by refactoring to reduce code duplication.

LayoutTests:

Added test for the filtering of *::marker selector from the rule results of CSS.getMatchedStyleForNode on
elements that don't support ::marker.

  • inspector/css/getMatchedStylesForNode-expected.txt:
  • Updated expectations to account for the abscence of the ::marker rule on non-list elements.
  • inspector/css/getMatchedStylesForNodeMarkerPseudoId-expected.txt: Added.
  • inspector/css/getMatchedStylesForNodeMarkerPseudoId.html: Added.
9:51 AM Changeset in webkit [273820] by Kate Cheney
  • 15 edits
    1 move
    7 adds in trunk

Report the correct document uri in the case of a ContentSecurityPolicyClient
https://bugs.webkit.org/show_bug.cgi?id=222489
<rdar://problem/73774118>

Reviewed by Brent Fulgham.

Source/WebCore:

Tests: http/tests/security/contentSecurityPolicy/report-document-uri-after-blocked-redirect.html

http/tests/security/contentSecurityPolicy/report-document-uri-blob.html

Previously we were setting the document URI to be the blocked URI in
the case where we were using a ContentSecurityPolicyClient and didn't
have access to the document URL. This patch passes the document URL
to the network process when loading a resource so we can properly set
the document URI in this case.

  • page/csp/ContentSecurityPolicy.cpp:

(WebCore::shouldReportProtocolOnly):
(WebCore::ContentSecurityPolicy::deprecatedURLForReporting const):
(WebCore::ContentSecurityPolicy::reportViolation const):
Follow spec guidelines https://www.w3.org/TR/CSP2/#violation-reports
and set the document URI to be the URI's scheme if it is a globally
unique identifier.

In the case where we are using a client and don't have the document
URL, we should at least strip the blocked URL before reporting to align
with the spec.

  • page/csp/ContentSecurityPolicy.h:

(WebCore::ContentSecurityPolicy::setDocumentURL):

Source/WebKit:

Pass the document URL from the Network Process when we schedule a load
in case we need to report a CSP violation in NetworkLoadChecker.

  • NetworkProcess/NetworkLoadChecker.cpp:

(WebKit::NetworkLoadChecker::NetworkLoadChecker):
(WebKit::NetworkLoadChecker::contentSecurityPolicy):
The regular toString() method sets file:// URLs to null. We should use
toRawString() so we can report the scheme if the source origin is a
local file, as per the W3C spec.

  • NetworkProcess/NetworkLoadChecker.h:
  • NetworkProcess/NetworkResourceLoadParameters.cpp:

(WebKit::NetworkResourceLoadParameters::encode const):
(WebKit::NetworkResourceLoadParameters::decode):

  • NetworkProcess/NetworkResourceLoadParameters.h:
  • NetworkProcess/NetworkResourceLoader.cpp:
  • NetworkProcess/PingLoad.cpp:

(WebKit::PingLoad::PingLoad):

  • WebProcess/Network/WebLoaderStrategy.cpp:

(WebKit::WebLoaderStrategy::scheduleLoadFromNetworkProcess):

Tools:

Rename OverrideContentSecurityPolicy.mm to ContentSecurityPolicy.mm
so we can use it for more general purpose CSP testing.

Add a test for document-uri reporting for file:, data: and about: protocols.

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WebKitCocoa/ContentSecurityPolicy.mm: Renamed from Tools/TestWebKitAPI/Tests/WebKitCocoa/OverrideContentSecurityPolicy.mm.

(TEST):

  • TestWebKitAPI/Tests/WebKitCocoa/csp-document-uri-report.html: Added.

LayoutTests:

Layout test coverage for redirects using a ContentSecurityPolicyClient
and blob files.

  • http/tests/security/contentSecurityPolicy/report-document-uri-blob-expected.txt: Added.
  • http/tests/security/contentSecurityPolicy/report-document-uri-blob.html: Added.
  • http/tests/security/contentSecurityPolicy/report-document-uri-after-blocked-redirect-expected.txt: Added.
  • http/tests/security/contentSecurityPolicy/report-document-uri-after-blocked-redirect.html: Added.
  • platform/mac-wk1/http/tests/security/contentSecurityPolicy/report-document-uri-after-blocked-redirect-expected.txt: Added.
  • platform/win/http/tests/security/contentSecurityPolicy/report-document-uri-after-blocked-redirect-expected.txt: Added.
  • platform/win/TestExpectations:

Blob URLs timeout on win.

9:14 AM Changeset in webkit [273819] by Chris Gambrell
  • 74 edits
    57 adds
    57 deletes in trunk/LayoutTests

[LayoutTests] Convert http/tests/misc convert PHP to Python
https://bugs.webkit.org/show_bug.cgi?id=221981
<rdar://problem/74399686>

Reviewed by Jonathan Bedard.

  • http/tests/fetch/fetch-in-worker.js:
  • http/tests/misc/401-alternative-content-expected.txt:
  • http/tests/misc/401-alternative-content.php: Removed.
  • http/tests/misc/401-alternative-content.py: Added.
  • http/tests/misc/async-script-removed.html:
  • http/tests/misc/async-script.html:
  • http/tests/misc/authentication-redirect-1/authentication-sent-to-redirect-cross-origin-expected.txt:
  • http/tests/misc/authentication-redirect-1/authentication-sent-to-redirect-cross-origin.html:
  • http/tests/misc/authentication-redirect-1/resources/auth-echo.php: Removed.
  • http/tests/misc/authentication-redirect-1/resources/auth-echo.py: Added.
  • http/tests/misc/authentication-redirect-1/resources/auth-then-redirect.php: Removed.
  • http/tests/misc/authentication-redirect-1/resources/auth-then-redirect.py: Added.
  • http/tests/misc/authentication-redirect-2/authentication-sent-to-redirect-same-origin-expected.txt:
  • http/tests/misc/authentication-redirect-2/authentication-sent-to-redirect-same-origin.html:
  • http/tests/misc/authentication-redirect-2/resources/auth-echo.php: Removed.
  • http/tests/misc/authentication-redirect-2/resources/auth-echo.py: Added.
  • http/tests/misc/authentication-redirect-2/resources/auth-then-redirect.php: Removed.
  • http/tests/misc/authentication-redirect-2/resources/auth-then-redirect.py: Added.
  • http/tests/misc/authentication-redirect-3/authentication-sent-to-redirect-same-origin-with-location-credentials-expected.txt:
  • http/tests/misc/authentication-redirect-3/authentication-sent-to-redirect-same-origin-with-location-credentials.html:
  • http/tests/misc/authentication-redirect-3/resources/auth-echo.php: Removed.
  • http/tests/misc/authentication-redirect-3/resources/auth-echo.py: Added.
  • http/tests/misc/authentication-redirect-3/resources/auth-then-redirect-with-url-credentials.php: Removed.
  • http/tests/misc/authentication-redirect-3/resources/auth-then-redirect-with-url-credentials.py: Added.
  • http/tests/misc/authentication-redirect-3/resources/auth-then-redirect.php: Removed.
  • http/tests/misc/authentication-redirect-3/resources/auth-then-redirect.py: Added.
  • http/tests/misc/authentication-redirect-4/authentication-sent-to-redirect-same-origin-url-expected.txt:
  • http/tests/misc/authentication-redirect-4/authentication-sent-to-redirect-same-origin-url.html:
  • http/tests/misc/authentication-redirect-4/resources/auth-echo.php: Removed.
  • http/tests/misc/authentication-redirect-4/resources/auth-echo.py: Added.
  • http/tests/misc/authentication-redirect-4/resources/auth-then-redirect.php: Removed.
  • http/tests/misc/authentication-redirect-4/resources/auth-then-redirect.py: Added.
  • http/tests/misc/bad-charset-alias.html:
  • http/tests/misc/before-unload-load-image.html:
  • http/tests/misc/char-encoding-bocu-1-blocklisted.html:
  • http/tests/misc/char-encoding-in-hidden-charset-field-default.html:
  • http/tests/misc/char-encoding-in-hidden-charset-field-with-Big5.html:
  • http/tests/misc/char-encoding-in-hidden-charset-field-with-EUC-JP.html:
  • http/tests/misc/char-encoding-in-hidden-charset-field-with-ISO-2022-JP.html:
  • http/tests/misc/char-encoding-in-hidden-charset-field-with-Shift_JIS.html:
  • http/tests/misc/char-encoding-in-hidden-charset-field-with-accept-charset.html:
  • http/tests/misc/char-encoding-in-hidden-charset-field-with-get-method.html:
  • http/tests/misc/char-encoding-in-hidden-charset-field-with-one-field.html:
  • http/tests/misc/char-encoding-in-text-charset-field-with-value.html:
  • http/tests/misc/char-encoding-scsu-blocklisted.html:
  • http/tests/misc/char-encoding-without-charset-field.html:
  • http/tests/misc/charset-sniffer-end-sniffing.html:
  • http/tests/misc/css-reject-any-type-in-strict-mode-expected.txt:
  • http/tests/misc/css-reject-any-type-in-strict-mode.html:
  • http/tests/misc/dns-prefetch-control.html:
  • http/tests/misc/embed-image-load-outlives-gc-without-crashing.html:
  • http/tests/misc/empty-file-formdata.html:
  • http/tests/misc/extract-http-content-language-against-equiv.php: Removed.
  • http/tests/misc/extract-http-content-language-against-equiv.py: Added.
  • http/tests/misc/extract-http-content-language-malformed.php: Removed.
  • http/tests/misc/extract-http-content-language-malformed.py: Added.
  • http/tests/misc/extract-http-content-language-multiple.php: Removed.
  • http/tests/misc/extract-http-content-language-multiple.py: Added.
  • http/tests/misc/extract-http-content-language.php: Removed.
  • http/tests/misc/extract-http-content-language.py: Added.
  • http/tests/misc/form-blob-challenge.html:
  • http/tests/misc/form-post-textplain-cross-site.html:
  • http/tests/misc/form-post-textplain.html:
  • http/tests/misc/form-submit-file-cross-site-redirect.html:
  • http/tests/misc/form-submit-file-cross-site.html:
  • http/tests/misc/image-checks-for-accept.html:
  • http/tests/misc/image-error.html:
  • http/tests/misc/image-input-type-outlives-gc-without-crashing.html:
  • http/tests/misc/image-load-outlives-gc-without-crashing.html:
  • http/tests/misc/javascript-url-stop-loaders.html:
  • http/tests/misc/large-js-program.php: Removed.
  • http/tests/misc/large-js-program.py: Added.
  • http/tests/misc/location-with-space.php: Removed.
  • http/tests/misc/location-with-space.py: Added.
  • http/tests/misc/mask-image-accept.html:
  • http/tests/misc/object-image-error.html:
  • http/tests/misc/object-image-load-outlives-gc-without-crashing.html:
  • http/tests/misc/redirect-to-about-blank.html:
  • http/tests/misc/redirect-to-external-url-expected.txt:
  • http/tests/misc/redirect-with-quotes.php: Removed.
  • http/tests/misc/redirect-with-quotes.py: Added.
  • http/tests/misc/redirect.php: Removed.
  • http/tests/misc/redirect.py: Added.
  • http/tests/misc/referrer.html:
  • http/tests/misc/refresh-headers.php: Removed.
  • http/tests/misc/refresh-headers.py: Added.
  • http/tests/misc/resources/3rd-level-iframe-with-blocking-resource.php: Removed.
  • http/tests/misc/resources/3rd-level-iframe-with-blocking-resource.py: Added.
  • http/tests/misc/resources/404image.php: Removed.
  • http/tests/misc/resources/404image.py: Added.
  • http/tests/misc/resources/SVGFont-delayed-loader.svg:
  • http/tests/misc/resources/bad-charset-alias.php: Removed.
  • http/tests/misc/resources/bad-charset-alias.py: Added.
  • http/tests/misc/resources/basic-echo-post.php: Removed.
  • http/tests/misc/resources/basic-echo-post.py: Added.
  • http/tests/misc/resources/bocu-1-cyrillic.php: Removed.
  • http/tests/misc/resources/bocu-1-cyrillic.py: Added.
  • http/tests/misc/resources/char-encoding-in-hidden-charset-field.php: Removed.
  • http/tests/misc/resources/char-encoding-in-hidden-charset-field.py: Added.
  • http/tests/misc/resources/charset-sniffer-end-sniffing.php: Removed.
  • http/tests/misc/resources/charset-sniffer-end-sniffing.py: Added.
  • http/tests/misc/resources/check-keygen-post.php: Removed.
  • http/tests/misc/resources/check-keygen-post.py: Added.
  • http/tests/misc/resources/check-test-file.php: Removed.
  • http/tests/misc/resources/check-test-file.py: Added.
  • http/tests/misc/resources/check-unnamed-file-included-in-formdata.php: Removed.
  • http/tests/misc/resources/check-unnamed-file-included-in-formdata.py: Added.
  • http/tests/misc/resources/delayed-log.php: Removed.
  • http/tests/misc/resources/delayed-log.py: Added.
  • http/tests/misc/resources/dns-prefetch-control.php: Removed.
  • http/tests/misc/resources/dns-prefetch-control.py: Added.
  • http/tests/misc/resources/echo-query-param.php: Removed.
  • http/tests/misc/resources/echo-query-param.py: Added.
  • http/tests/misc/resources/form-post-textplain.php: Removed.
  • http/tests/misc/resources/form-post-textplain.py: Added.
  • http/tests/misc/resources/hang-connection.php: Removed.
  • http/tests/misc/resources/hang-connection.py: Added.
  • http/tests/misc/resources/image-checks-for-accept.php: Removed.
  • http/tests/misc/resources/image-checks-for-accept.py: Added.
  • http/tests/misc/resources/nested-iframe-loading-another-iframe.html:
  • http/tests/misc/resources/protected/protected-image.php: Removed.
  • http/tests/misc/resources/protected/protected-image.py: Added.
  • http/tests/misc/resources/random-no-store.php: Removed.
  • http/tests/misc/resources/random-no-store.py: Added.
  • http/tests/misc/resources/redirect-result.php: Removed.
  • http/tests/misc/resources/redirect-result.py: Added.
  • http/tests/misc/resources/redirect-step2.php: Removed.
  • http/tests/misc/resources/redirect-step2.py: Added.
  • http/tests/misc/resources/redirect-step3.php: Removed.
  • http/tests/misc/resources/redirect-step3.py: Added.
  • http/tests/misc/resources/redirect-step4.php: Removed.
  • http/tests/misc/resources/redirect-step4.py: Added.
  • http/tests/misc/resources/redirect-to-about-blank.php: Removed.
  • http/tests/misc/resources/redirect-to-about-blank.py: Added.
  • http/tests/misc/resources/redirect-to-external-url-iframe.html:
  • http/tests/misc/resources/redirect-to-external-url.php: Removed.
  • http/tests/misc/resources/redirect-to-external-url.py: Added.
  • http/tests/misc/resources/referrer-main-resource.php: Removed.
  • http/tests/misc/resources/referrer-main-resource.py: Added.
  • http/tests/misc/resources/referrer-result.php: Removed.
  • http/tests/misc/resources/referrer-result.py: Added.
  • http/tests/misc/resources/script-500.php: Removed.
  • http/tests/misc/resources/script-500.py: Added.
  • http/tests/misc/resources/scsu-cyrillic.php: Removed.
  • http/tests/misc/resources/scsu-cyrillic.py: Added.
  • http/tests/misc/resources/send-async-xhr.html:
  • http/tests/misc/resources/slowimage.php: Removed.
  • http/tests/misc/resources/slowimage.py: Added.
  • http/tests/misc/resources/stylesheet-bad-mime-type.php: Removed.
  • http/tests/misc/resources/stylesheet-bad-mime-type.py: Added.
  • http/tests/misc/resources/webtiming-cross-origin-and-back-redirect1.php: Removed.
  • http/tests/misc/resources/webtiming-cross-origin-and-back-redirect1.py: Added.
  • http/tests/misc/resources/webtiming-cross-origin-and-back-redirect2.php: Removed.
  • http/tests/misc/resources/webtiming-cross-origin-and-back-redirect2.py: Added.
  • http/tests/misc/script-500.html:
  • http/tests/misc/script-no-store.html:
  • http/tests/misc/submit-post-keygen.html:
  • http/tests/misc/svg-image-load-outlives-gc-without-crashing.html:
  • http/tests/misc/timer-vs-loading.html:
  • http/tests/misc/url-in-utf16be.html:
  • http/tests/misc/url-in-utf16le.html:
  • http/tests/misc/video-poster-image-load-outlives-gc-without-crashing.html:
  • http/tests/misc/webtiming-cross-origin-and-back1.html:
  • http/tests/misc/webtiming-cross-origin-redirect.php: Removed.
  • http/tests/misc/webtiming-cross-origin-redirect.py: Added.
  • http/tests/misc/webtiming-one-redirect.php: Removed.
  • http/tests/misc/webtiming-one-redirect.py: Added.
  • http/tests/misc/webtiming-slow-load.php: Removed.
  • http/tests/misc/webtiming-slow-load.py: Added.
  • http/tests/misc/webtiming-ssl.php: Removed.
  • http/tests/misc/webtiming-ssl.py: Added.
  • http/tests/misc/webtiming-two-redirects.php: Removed.
  • http/tests/misc/webtiming-two-redirects.py: Added.
  • http/tests/misc/xhtml.php: Removed.
  • http/tests/misc/xhtml.py: Added.
  • http/tests/xmlhttprequest/on-network-timeout-error-during-preflight.html:
  • http/tests/xmlhttprequest/resetting-timeout-to-zero.html:
  • http/tests/xmlhttprequest/timeout-greater-than-default-network-timeout.html:
  • platform/gtk/TestExpectations:
  • platform/ios/TestExpectations:
  • platform/mac/TestExpectations:
  • platform/win/TestExpectations:
  • platform/win/http/tests/loading/basic-auth-load-URL-with-consecutive-slashes-expected.txt:
  • platform/wk2/http/tests/misc/authentication-redirect-1/authentication-sent-to-redirect-cross-origin-expected.txt:
  • platform/wk2/http/tests/misc/authentication-redirect-2/authentication-sent-to-redirect-same-origin-expected.txt:
  • platform/wk2/http/tests/misc/authentication-redirect-3/authentication-sent-to-redirect-same-origin-with-location-credentials-expected.txt:
  • platform/wk2/http/tests/misc/authentication-redirect-4/authentication-sent-to-redirect-same-origin-url-expected.txt:
9:11 AM Changeset in webkit [273818] by youenn@apple.com
  • 2 edits in trunk/LayoutTests

[GPUP] imported/w3c/web-platform-tests/webrtc/RTCRtpSender-replaceTrack.https.html times out with GPU Process enabled
https://bugs.webkit.org/show_bug.cgi?id=222505
<rdar://problem/74814573>

Unreviewed.

  • gpu-process/TestExpectations:

Test is no longer timing out on GPUProcess bot.

8:55 AM Changeset in webkit [273817] by youenn@apple.com
  • 6 edits in trunk

WebKitLegacy needs to keep JSDOMWindow even though it is used while its origin is not set
https://bugs.webkit.org/show_bug.cgi?id=222589
<rdar://problem/74258258>

Reviewed by Geoffrey Garen.

Source/WebCore:

Use the new flag to allow reuse of JSDOMWindow objects even though they are created at a time where its SecurityOrigin is not set yet.
This allows keeping WebKitLegacy existing functionality.

Covered by API test.

  • bindings/js/JSWindowProxy.cpp:

(WebCore::JSWindowProxy::setWindow):

Source/WTF:

  • Scripts/Preferences/WebPreferencesInternal.yaml:

Introduce a flag, on for WebKit and off for WebKitLegacy.

Tools:

  • TestWebKitAPI/Tests/mac/JSWrapperForNodeInWebFrame.mm:

(TestWebKitAPI::TEST):

8:37 AM Changeset in webkit [273816] by Alexey Shvayka
  • 4 edits
    2 adds in trunk

Add JSModuleNamespaceObject::deletePropertyByIndex() method
https://bugs.webkit.org/show_bug.cgi?id=222611

Reviewed by Yusuke Suzuki.

JSTests:

  • modules/arbitrary-module-names-indexed.js: Added.
  • modules/arbitrary-module-names/export-indexed.js: Added.

Source/JavaScriptCore:

r270923 introduced arbitrary module namespace identifiers, enabling indexed identifiers
to be exported. While they were already handled by getOwnPropertySlotByIndex(), indexed
Delete override was absent, which prevented TypeError from being thrown.

This patch adds the missing method, aligning JSC with the spec [1].

[1]: https://tc39.es/ecma262/#sec-module-namespace-exotic-objects-delete-p

  • runtime/JSModuleNamespaceObject.cpp:

(JSC::JSModuleNamespaceObject::deleteProperty):
(JSC::JSModuleNamespaceObject::deletePropertyByIndex):

  • runtime/JSModuleNamespaceObject.h:
8:34 AM Changeset in webkit [273815] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC][IFC] Enable simplified vertical alignment for empty inline boxes
https://bugs.webkit.org/show_bug.cgi?id=222630

Reviewed by Antti Koivisto.

This patch enables the simplified vertical alignment for cases when the line has non-stretching empty inline boxes.
e.g.
<div>text<span></span>content</div>
but not
<div>text<span style="font-size: 100px"></span>content</div> (in standards mode the empty inline box starts with a strut, so this would be stretching the root inline box to ~100px).

  • layout/inlineformatting/InlineFormattingContextGeometry.cpp:

(WebCore::Layout::LineBoxBuilder::constructAndAlignInlineLevelBoxes):
(WebCore::Layout::LineBoxBuilder::SimplifiedVerticalAlignment::canUseSimplifiedAlignment):
(WebCore::Layout::LineBoxBuilder::SimplifiedVerticalAlignment::align):

  • layout/inlineformatting/InlineLineBox.h:

(WebCore::Layout::LineBox::InlineLevelBox::LayoutBounds::operator== const):

8:02 AM Changeset in webkit [273814] by don.olmstead@sony.com
  • 26 edits in trunk

[CMake] JavaScriptCore GLib headers should be copies
https://bugs.webkit.org/show_bug.cgi?id=222625

Reviewed by Michael Catanzaro.

.:

Specify the directories for JavaScriptCore GLib headers and derived sources.

  • Source/cmake/OptionsGTK.cmake:
  • Source/cmake/OptionsWPE.cmake:

Source/JavaScriptCore:

Copy the headers rather than creating a symbolic link to structure the JavaScriptCore Glib
headers into a jsc directory. This follows the convention used in JavaScriptCore where
there are public and private headers.

The public JavaScriptCore GLib headers are copied before building JavaScriptCore. The
private JavaScriptCore were modified to include the public GLib headers through
<jsc/Header.h> rather than "Header.h" which is convention for the private C APIs in
JavaScriptCore.

APICast.h was being erroneously included in JSCClassPrivate.h because its not a
JavaScriptCore GLib header. Instead forward declarations were added to the private headers
and APICast.h was used as necessary in the .cpp files.

  • API/glib/JSCClassPrivate.h:
  • API/glib/JSCContext.cpp:
  • API/glib/JSCContextPrivate.h:
  • API/glib/JSCExceptionPrivate.h:
  • API/glib/JSCValuePrivate.h:
  • API/glib/JSCVirtualMachine.cpp:
  • API/glib/JSCVirtualMachinePrivate.h:
  • API/glib/JSCWrapperMap.cpp:
  • GLib.cmake:
  • PlatformGTK.cmake:

Source/WebKit:

Update the includes for the GLib ports.

  • PlatformGTK.cmake:
  • PlatformWPE.cmake:
  • WebProcess/InjectedBundle/API/glib/DOM/WebKitDOMNode.cpp:
  • WebProcess/InjectedBundle/API/glib/WebKitFrame.cpp:

Tools:

Update the includes for the GLib ports.

  • MiniBrowser/wpe/CMakeLists.txt:
  • TestWebKitAPI/PlatformGTK.cmake:
  • TestWebKitAPI/PlatformWPE.cmake:
  • TestWebKitAPI/Tests/JavaScriptCore/glib/TestJSC.cpp:
  • TestWebKitAPI/glib/CMakeLists.txt:
  • TestWebKitAPI/glib/PlatformGTK.cmake:
4:20 AM Changeset in webkit [273813] by commit-queue@webkit.org
  • 24 edits in trunk/Source/JavaScriptCore

[WASM-Function-References] Extend wasm type with type index
https://bugs.webkit.org/show_bug.cgi?id=222351

Patch by Dmitry Bezhetskov <dbezhetskov> on 2021-03-03
Reviewed by Keith Miller.

Extend wasm type with type index to represent
new reference types from typed function references
proposal: https://github.com/WebAssembly/function-references/blob/master/proposals/function-references/Overview.md.

  • bytecode/BytecodeDumper.cpp:

(JSC::Wasm::BytecodeDumper::dumpConstants):
(JSC::Wasm::BytecodeDumper::formatConstant const):

  • bytecode/BytecodeDumper.h:
  • wasm/WasmAirIRGenerator.cpp:

(JSC::Wasm::TypedTmp::TypedTmp):
(JSC::Wasm::TypedTmp::dump const):
(JSC::Wasm::AirIRGenerator::g32):
(JSC::Wasm::AirIRGenerator::g64):
(JSC::Wasm::AirIRGenerator::gExternref):
(JSC::Wasm::AirIRGenerator::gFuncref):
(JSC::Wasm::AirIRGenerator::f32):
(JSC::Wasm::AirIRGenerator::f64):
(JSC::Wasm::AirIRGenerator::tmpForType):
(JSC::Wasm::AirIRGenerator::emitCCall):
(JSC::Wasm::AirIRGenerator::moveOpForValueType):
(JSC::Wasm::AirIRGenerator::AirIRGenerator):
(JSC::Wasm::AirIRGenerator::addLocal):
(JSC::Wasm::AirIRGenerator::addConstant):
(JSC::Wasm::AirIRGenerator::addRefIsNull):
(JSC::Wasm::AirIRGenerator::addRefFunc):
(JSC::Wasm::AirIRGenerator::addTableGet):
(JSC::Wasm::AirIRGenerator::addTableSet):
(JSC::Wasm::AirIRGenerator::addTableInit):
(JSC::Wasm::AirIRGenerator::addElemDrop):
(JSC::Wasm::AirIRGenerator::addTableSize):
(JSC::Wasm::AirIRGenerator::addTableGrow):
(JSC::Wasm::AirIRGenerator::addTableFill):
(JSC::Wasm::AirIRGenerator::addTableCopy):
(JSC::Wasm::AirIRGenerator::addGrowMemory):
(JSC::Wasm::AirIRGenerator::addCurrentMemory):
(JSC::Wasm::AirIRGenerator::addMemoryFill):
(JSC::Wasm::AirIRGenerator::addMemoryCopy):
(JSC::Wasm::AirIRGenerator::addMemoryInit):
(JSC::Wasm::AirIRGenerator::addDataDrop):
(JSC::Wasm::AirIRGenerator::emitCheckAndPreparePointer):
(JSC::Wasm::AirIRGenerator::sanitizeAtomicResult):
(JSC::Wasm::AirIRGenerator::appendGeneralAtomic):
(JSC::Wasm::AirIRGenerator::appendStrongCAS):
(JSC::Wasm::AirIRGenerator::emitAtomicLoadOp):
(JSC::Wasm::AirIRGenerator::atomicLoad):
(JSC::Wasm::AirIRGenerator::emitAtomicStoreOp):
(JSC::Wasm::AirIRGenerator::emitAtomicBinaryRMWOp):
(JSC::Wasm::AirIRGenerator::atomicBinaryRMW):
(JSC::Wasm::AirIRGenerator::emitAtomicCompareExchange):
(JSC::Wasm::AirIRGenerator::atomicCompareExchange):
(JSC::Wasm::AirIRGenerator::atomicWait):
(JSC::Wasm::AirIRGenerator::atomicNotify):
(JSC::Wasm::AirIRGenerator::truncSaturated):
(JSC::Wasm::AirIRGenerator::addReturn):
(JSC::Wasm::AirIRGenerator::addSwitch):
(JSC::Wasm::AirIRGenerator::emitModOrDiv):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I32TruncSF64>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I32TruncSF32>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I32TruncUF64>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I32TruncUF32>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I64TruncSF64>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I64TruncUF64>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I64TruncSF32>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I64TruncUF32>):
(JSC::Wasm::AirIRGenerator::addShift):
(JSC::Wasm::AirIRGenerator::addFloatingPointBinOp):
(JSC::Wasm::AirIRGenerator::addOp<OpType::F32Min>):
(JSC::Wasm::AirIRGenerator::addFloatingPointMinOrMax):
(JSC::Wasm::AirIRGenerator::addOp<OpType::F32Max>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::F64Mul>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::F32Div>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::F64Div>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::F32Neg>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I64Rotr>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I64Rotl>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I32ShrU>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I32ShrS>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I32Shl>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::F64Min>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::F64Sub>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I64ShrS>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I64ShrU>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I64Shl>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I32Rotl>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I32Rotr>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::F64Neg>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::F64Max>):

  • wasm/WasmB3IRGenerator.cpp:

(JSC::Wasm::B3IRGenerator::addTableGet):
(JSC::Wasm::B3IRGenerator::addRefFunc):
(JSC::Wasm::B3IRGenerator::addTableInit):
(JSC::Wasm::B3IRGenerator::addTableSize):
(JSC::Wasm::B3IRGenerator::addTableGrow):
(JSC::Wasm::B3IRGenerator::addTableFill):
(JSC::Wasm::B3IRGenerator::addTableCopy):
(JSC::Wasm::B3IRGenerator::addMemoryFill):
(JSC::Wasm::B3IRGenerator::addMemoryInit):
(JSC::Wasm::B3IRGenerator::addMemoryCopy):
(JSC::Wasm::B3IRGenerator::sanitizeAtomicResult):
(JSC::Wasm::B3IRGenerator::atomicLoad):
(JSC::Wasm::B3IRGenerator::emitAtomicStoreOp):
(JSC::Wasm::B3IRGenerator::emitAtomicBinaryRMWOp):
(JSC::Wasm::B3IRGenerator::atomicBinaryRMW):
(JSC::Wasm::B3IRGenerator::emitAtomicCompareExchange):
(JSC::Wasm::B3IRGenerator::atomicCompareExchange):

  • wasm/WasmCallingConvention.h:

(JSC::Wasm::WasmCallingConvention::marshallLocation const):
(JSC::Wasm::WasmCallingConvention::callInformationFor const):
(JSC::Wasm::JSCallingConvention::marshallLocation const):

  • wasm/WasmFormat.h:

(JSC::Wasm::isValueType):
(JSC::Wasm::isRefType):
(JSC::Wasm::TableInformation::wasmType const):

  • wasm/WasmFunctionCodeBlock.h:
  • wasm/WasmFunctionParser.h:

(JSC::Wasm::FunctionParser::TypedExpression::TypedExpression):
(JSC::Wasm::FunctionParser<Context>::load):
(JSC::Wasm::FunctionParser<Context>::store):
(JSC::Wasm::FunctionParser<Context>::atomicLoad):
(JSC::Wasm::FunctionParser<Context>::atomicStore):
(JSC::Wasm::FunctionParser<Context>::atomicBinaryRMW):
(JSC::Wasm::FunctionParser<Context>::atomicCompareExchange):
(JSC::Wasm::FunctionParser<Context>::atomicWait):
(JSC::Wasm::FunctionParser<Context>::atomicNotify):
(JSC::Wasm::FunctionParser<Context>::checkBranchTarget):
(JSC::Wasm::FunctionParser<Context>::unify):
(JSC::Wasm::FunctionParser<Context>::parseExpression):

  • wasm/WasmGlobal.cpp:

(JSC::Wasm::Global::get const):
(JSC::Wasm::Global::set):
(JSC::Wasm::Global::visitAggregateImpl):

  • wasm/WasmLLIntGenerator.cpp:

(JSC::Wasm::LLIntGenerator::jsNullConstant):
(JSC::Wasm::LLIntGenerator::zeroConstant):
(JSC::Wasm::LLIntGenerator::callInformationForCaller):
(JSC::Wasm::LLIntGenerator::callInformationForCallee):
(JSC::Wasm::LLIntGenerator::addArguments):
(JSC::Wasm::LLIntGenerator::addLocal):

  • wasm/WasmOperations.cpp:

(JSC::Wasm::JSC_DEFINE_JIT_OPERATION):

  • wasm/WasmParser.h:

(JSC::Wasm::Parser<SuccessType>::parseBlockSignature):
(JSC::Wasm::Parser<SuccessType>::parseValueType):

  • wasm/WasmSectionParser.cpp:

(JSC::Wasm::SectionParser::parseType):
(JSC::Wasm::SectionParser::parseTableHelper):
(JSC::Wasm::SectionParser::parseGlobal):
(JSC::Wasm::SectionParser::parseElement):
(JSC::Wasm::SectionParser::parseInitExpr):
(JSC::Wasm::SectionParser::parseI32InitExpr):
(JSC::Wasm::SectionParser::parseElementSegmentVectorOfExpressions):

  • wasm/WasmSignature.cpp:

(JSC::Wasm::Signature::dump const):
(JSC::Wasm::computeHash):
(JSC::Wasm::SignatureInformation::SignatureInformation):

  • wasm/WasmSignature.h:

(JSC::Wasm::SignatureInformation::thunkFor const):

  • wasm/WasmTable.cpp:

(JSC::Wasm::Table::wasmType const):

  • wasm/generateWasmOpsHeader.py:

(TypeKind):

  • wasm/js/JSToWasm.cpp:

(JSC::Wasm::marshallJSResult):
(JSC::Wasm::createJSToWasmWrapper):

  • wasm/js/JSWebAssemblyHelpers.h:

(JSC::defaultValueForReferenceType):

  • wasm/js/WasmToJS.cpp:

(JSC::Wasm::wasmToJS):

  • wasm/js/WebAssemblyFunction.cpp:

(JSC::JSC_DEFINE_HOST_FUNCTION):
(JSC::WebAssemblyFunction::jsCallEntrypointSlow):

  • wasm/js/WebAssemblyGlobalConstructor.cpp:

(JSC::JSC_DEFINE_HOST_FUNCTION):

  • wasm/js/WebAssemblyModuleRecord.cpp:

(JSC::WebAssemblyModuleRecord::linkImpl):

Note: See TracTimeline for information about the timeline view.