Add SPI to canonicalize NSURLs with WTF::URL
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 1 Apr 2019 18:21:01 +0000 (18:21 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 1 Apr 2019 18:21:01 +0000 (18:21 +0000)
commit5c0f3f30fc76573f8b54fe03f43cb64eb189165a
treea2417dfcabe8358e889bc5b4c98ce65e35e6dbc7
parent4a30625d24cdabd44a41c103a4a316f6a5fb8789
Add SPI to canonicalize NSURLs with WTF::URL
https://bugs.webkit.org/show_bug.cgi?id=196415
<rdar://problem/44980271>

Patch by Alex Christensen <achristensen@webkit.org> on 2019-04-01
Reviewed by Darin Adler.

Source/WebKitLegacy/mac:

* Misc/WebNSURLExtras.h:
* Misc/WebNSURLExtras.mm:
(-[NSURL _webkit_canonicalize_with_wtf]):
_webkit_canonicalize is old and changing it causes strange bugs like rdar://problem/5315926
Instead, make a new version that uses WTF::URL to canonicalize an NSURL.

Tools:

* TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
* TestWebKitAPI/Tests/WebKitLegacy/mac/URLCanonicalization.mm: Added.
(TestWebKitAPI::TEST):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@243698 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebKitLegacy/mac/ChangeLog
Source/WebKitLegacy/mac/Misc/WebNSURLExtras.h
Source/WebKitLegacy/mac/Misc/WebNSURLExtras.mm
Tools/ChangeLog
Tools/TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj
Tools/TestWebKitAPI/Tests/WebKitLegacy/mac/URLCanonicalization.mm [new file with mode: 0644]