dc65fff7b8
https://bugs.webkit.org/show_bug.cgi?id=228287 Reviewed by Darin Adler. LayoutTests/imported/w3c: Rebaseline a few WPT tests now that more checks are passing. * web-platform-tests/html/semantics/scripting-1/the-script-element/execution-timing/083-expected.txt: * web-platform-tests/html/semantics/scripting-1/the-script-element/execution-timing/084-expected.txt: * web-platform-tests/html/webappapis/scripting/processing-model-2/window-onerror-with-cross-frame-event-listeners-1-expected.txt: * web-platform-tests/html/webappapis/scripting/processing-model-2/window-onerror-with-cross-frame-event-listeners-2-expected.txt: Source/WebCore: Location::setLocation() is using "firstWindow" to resolve any input relative URL. We rely on JSC::VM::deprecatedVMEntryGlobalObject() to get the first/entry window. However, the test I wrote shows that we were using the wrong window as "first window" in some cases (since this test would pass in other browsers but not in WebKit). It turns out that JSEventListener::handleEvent() had a VMEntryScope internally that would impact the global object being returned by JSC::VM::deprecatedVMEntryGlobalObject(). We were incorrectly using the scriptExecutionContext passed as parameter when constructing the VMEntryScope instead of using the global object of the function we're about to call. This bug addresses this. Credits to Geoff Garen for identifying the issue in JSEventListener::handleEvent(). Test: http/tests/dom/window-location-set-href-relative-url.html * bindings/js/JSEventListener.cpp: (WebCore::JSEventListener::handleEvent): * page/Location.cpp: (WebCore::Location::setLocation): LayoutTests: Add layout test coverage. This test is passing in Chome and Firefox but was failing with WebKit. * http/tests/dom/window-location-set-href-relative-url-expected.txt: Added. * http/tests/dom/window-location-set-href-relative-url.html: Added. Canonical link: https://commits.webkit.org/239980@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@280333 268f45cc-cd09-0410-ab3c-d52691b4dbfc |
||
---|---|---|
.. | ||
animation | ||
backgrounds | ||
beacon | ||
block | ||
borders | ||
box-shadow | ||
canvas | ||
clip | ||
cpu | ||
css | ||
css-generated-content | ||
css-grid-layout | ||
css-intrinsic-dimensions | ||
css3-text/css3-text-decoration | ||
dom | ||
dynamic | ||
encoding | ||
events | ||
forms | ||
frames | ||
gradients | ||
hidpi | ||
history | ||
html | ||
images | ||
inline | ||
layers | ||
layout | ||
lists | ||
loader | ||
masking | ||
media | ||
multicol | ||
overflow | ||
pagination | ||
parser | ||
plugins | ||
repaint | ||
replaced | ||
ruby | ||
scrolling | ||
shapes | ||
sub-pixel | ||
table | ||
text | ||
text-autosizing | ||
transforms | ||
url | ||
workers | ||
writing-mode | ||
xsl |