Unreviewed, follow-up fix after r212972.
authorcdumez@apple.com <cdumez@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 25 Feb 2017 03:23:10 +0000 (03:23 +0000)
committercdumez@apple.com <cdumez@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 25 Feb 2017 03:23:10 +0000 (03:23 +0000)
Fixes a few assertions on the debug build bots.
URL needs to be exactly the same as the parsed one given
that we are calling the ParsedURLString constructor.

* platform/network/ResourceResponseBase.cpp:
(WebCore::ResourceResponseBase::sanitizeSuggestedFilename):

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

Source/WebCore/ChangeLog
Source/WebCore/platform/network/ResourceResponseBase.cpp

index 15a3c42..757b0b9 100644 (file)
@@ -1,3 +1,14 @@
+2017-02-24  Chris Dumez  <cdumez@apple.com>
+
+        Unreviewed, follow-up fix after r212972.
+
+        Fixes a few assertions on the debug build bots.
+        URL needs to be exactly the same as the parsed one given
+        that we are calling the ParsedURLString constructor.
+
+        * platform/network/ResourceResponseBase.cpp:
+        (WebCore::ResourceResponseBase::sanitizeSuggestedFilename):
+
 2017-02-24  Zalan Bujtas  <zalan@apple.com>
 
         Simple line layout: Re-adjust paginated lines when block height changes.
index 27bd579..92a014c 100644 (file)
@@ -229,7 +229,7 @@ String ResourceResponseBase::sanitizeSuggestedFilename(const String& suggestedFi
     if (suggestedFilename.isEmpty())
         return suggestedFilename;
 
-    ResourceResponse response(URL(ParsedURLString, "http://example.com"), String(), -1, String());
+    ResourceResponse response(URL(ParsedURLString, "http://example.com/"), String(), -1, String());
     response.setHTTPStatusCode(200);
     String escapedSuggestedFilename = String(suggestedFilename).replace('\"', "\\\"");
     String value = makeString("attachment; filename=\"", escapedSuggestedFilename, '"');