Use createCFURLFromBuffer when converting a String to a CFURL
authormitz@apple.com <mitz@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 10 Nov 2013 06:49:13 +0000 (06:49 +0000)
committermitz@apple.com <mitz@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 10 Nov 2013 06:49:13 +0000 (06:49 +0000)
commit82c9603e85fd16e875b55498cb5068b72feb1ebd
tree8534eb989053d825a969562f27b0171959b3a668
parent7d611d8deff01fc345d8e02a118447e3c82fcbc4
Use createCFURLFromBuffer when converting a String to a CFURL
https://bugs.webkit.org/show_bug.cgi?id=124113

Reviewed by Anders Carlsson.

* Shared/API/c/cf/WKURLCF.mm:
(WKURLCopyCFURL): Replaced some code with a call to createCFURLFromBuffer(), which does the
same thing.

* Shared/Cocoa/WKNSURLExtras.h: Added.
* Shared/Cocoa/WKNSURLExtras.mm: Added.
(+[NSURL _web_URLWithWTFString:relativeToURL:]): Added. Returns nil for the null String,
otherwise returns the result of createCFURLFromBuffer().

* UIProcess/API/Cocoa/WKBackForwardListItem.mm:
(-[WKBackForwardListItem URL]): Changed to use +_web_URLWithWTFString:relativeToURL:.
(-[WKBackForwardListItem originalURL]): Ditto.

* UIProcess/API/Cocoa/WKNavigationData.mm:
(-[WKNavigationData destinationURL]): Ditto.

* UIProcess/API/mac/WKBrowsingContextController.mm:
(-[WKBrowsingContextController unreachableURL]): Ditto.

* WebKit2.xcodeproj/project.pbxproj: Added references to new files.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@159016 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebKit2/ChangeLog
Source/WebKit2/Shared/API/c/cf/WKURLCF.mm
Source/WebKit2/Shared/Cocoa/WKNSURLExtras.h [new file with mode: 0644]
Source/WebKit2/Shared/Cocoa/WKNSURLExtras.mm [new file with mode: 0644]
Source/WebKit2/UIProcess/API/Cocoa/WKBackForwardListItem.mm
Source/WebKit2/UIProcess/API/Cocoa/WKNavigationData.mm
Source/WebKit2/UIProcess/API/mac/WKBrowsingContextController.mm
Source/WebKit2/WebKit2.xcodeproj/project.pbxproj