Summary: | Incorrect association of the URL object with the value port | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Ivan Demidov <scrum> | ||||||
Component: | DOM | Assignee: | Alex Christensen <achristensen> | ||||||
Status: | RESOLVED FIXED | ||||||||
Severity: | Normal | CC: | achristensen, cdumez, commit-queue, esprehn+autocc, ews-watchlist, gyuyoung.kim, sam, webkit-bug-importer | ||||||
Priority: | P2 | Keywords: | InRadar | ||||||
Version: | Safari 13 | ||||||||
Hardware: | Unspecified | ||||||||
OS: | Unspecified | ||||||||
Attachments: |
|
Description
Ivan Demidov
2019-11-20 09:54:43 PST
Created attachment 384223 [details]
Patch
Created attachment 384230 [details]
Patch
Comment on attachment 384230 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=384230&action=review > Source/WebCore/html/URLUtils.h:236 > + unsigned port = value.toUInt(&success); Not related to this change, but it's a bit odd we use toUInt() here, rather than toUIntStrict(), since the former allows trailing garbage. Probably worth testing, but not in this change. (I also kind of want to change the toNumber functions to return Optionals). Chromium allows trailing garbage, Firefox does not, the spec is a little unclear and seems to me that it would allow url.port="123?query" to override the path and query, but no browser allows that. I'm going to commit this as-is right now to save the toUIntStrict discussion for another day, because it doesn't seem to be causing compatibility problems in practice now. Comment on attachment 384230 [details] Patch Clearing flags on attachment: 384230 Committed r252998: <https://trac.webkit.org/changeset/252998> All reviewed patches have been landed. Closing bug. |