WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
153121
window.location.replace with invalid URL should throw
https://bugs.webkit.org/show_bug.cgi?id=153121
Summary
window.location.replace with invalid URL should throw
Adrian
Reported
2016-01-15 04:15:35 PST
Steps to reproduce Go to any site Open the console Type window.location.replace('//') What should happen? As per spec
https://www.w3.org/TR/html5/browsers.html#dom-location-replace
it should throw an exception What actually happen? It shows a error html page saying "Safari can't open the page "
https:whatever/
" because the page's address is invalid" and doesn't throw at all.
Attachments
Patch
(6.56 KB, patch)
2020-06-28 08:29 PDT
,
Rob Buis
no flags
Details
Formatted Diff
Diff
Patch
(6.57 KB, patch)
2020-06-28 08:40 PDT
,
Rob Buis
no flags
Details
Formatted Diff
Diff
Patch
(6.61 KB, patch)
2020-06-28 11:03 PDT
,
Rob Buis
no flags
Details
Formatted Diff
Diff
Patch
(6.56 KB, patch)
2020-06-28 23:59 PDT
,
Rob Buis
no flags
Details
Formatted Diff
Diff
Show Obsolete
(3)
View All
Add attachment
proposed patch, testcase, etc.
Rob Buis
Comment 1
2020-06-28 08:29:01 PDT
Created
attachment 402997
[details]
Patch
EWS Watchlist
Comment 2
2020-06-28 08:29:40 PDT
This patch modifies the imported WPT tests. Please ensure that any changes on the tests (not coming from a WPT import) are exported to WPT. Please see
https://trac.webkit.org/wiki/WPTExportProcess
Rob Buis
Comment 3
2020-06-28 08:40:15 PDT
Created
attachment 402998
[details]
Patch
Rob Buis
Comment 4
2020-06-28 11:03:31 PDT
Created
attachment 403002
[details]
Patch
Rob Buis
Comment 5
2020-06-28 11:04:03 PDT
WPT test is exported as
https://github.com/web-platform-tests/wpt/pull/24374
.
Darin Adler
Comment 6
2020-06-28 13:11:19 PDT
Comment on
attachment 403002
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=403002&action=review
> Source/WebCore/page/Location.cpp:232 > + if (completedURL.isNull() || !completedURL.isValid())
I wonder if null URLs can ever be valid. If not, then the isNull check is not needed.
Rob Buis
Comment 7
2020-06-28 23:59:04 PDT
Created
attachment 403032
[details]
Patch
EWS
Comment 8
2020-06-29 01:04:15 PDT
Committed
r263647
: <
https://trac.webkit.org/changeset/263647
> All reviewed patches have been landed. Closing bug and clearing flags on
attachment 403032
[details]
.
Radar WebKit Bug Importer
Comment 9
2020-06-29 01:05:19 PDT
<
rdar://problem/64879675
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug