[curl] Can't load file:// URL with a URL fragment identifier
authordon.olmstead@sony.com <don.olmstead@sony.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 5 Jan 2018 23:13:35 +0000 (23:13 +0000)
committerdon.olmstead@sony.com <don.olmstead@sony.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 5 Jan 2018 23:13:35 +0000 (23:13 +0000)
https://bugs.webkit.org/show_bug.cgi?id=181170

Reviewed by Alex Christensen.

No new tests. No change in behavior.

* platform/network/curl/CurlRequest.cpp:
(WebCore::CurlRequest::invokeDidReceiveResponseForFile):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@226466 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/platform/network/curl/CurlRequest.cpp

index e09067a..1a5a077 100644 (file)
@@ -1,5 +1,17 @@
 2018-01-05  Don Olmstead  <don.olmstead@sony.com>
 
+        [curl] Can't load file:// URL with a URL fragment identifier
+        https://bugs.webkit.org/show_bug.cgi?id=181170
+
+        Reviewed by Alex Christensen.
+
+        No new tests. No change in behavior.
+
+        * platform/network/curl/CurlRequest.cpp:
+        (WebCore::CurlRequest::invokeDidReceiveResponseForFile):
+
+2018-01-05  Don Olmstead  <don.olmstead@sony.com>
+
         TextCodec uses std::array but does not include it
         https://bugs.webkit.org/show_bug.cgi?id=181340
 
index 9b7ea53..c03b0c2 100644 (file)
@@ -504,7 +504,7 @@ void CurlRequest::invokeDidReceiveResponseForFile(URL& url)
     m_response.statusCode = 200;
 
     // Determine the MIME type based on the path.
-    m_response.headers.append(String("Content-Type: " + MIMETypeRegistry::getMIMETypeForPath(m_response.url)));
+    m_response.headers.append(String("Content-Type: " + MIMETypeRegistry::getMIMETypeForPath(m_response.url.path())));
 
     if (!m_isSyncRequest) {
         // DidReceiveResponse must not be called immediately