summaryrefslogtreecommitdiffstats
path: root/webkit/glue/weburlloader_impl.cc
diff options
context:
space:
mode:
Diffstat (limited to 'webkit/glue/weburlloader_impl.cc')
-rw-r--r--webkit/glue/weburlloader_impl.cc9
1 files changed, 7 insertions, 2 deletions
diff --git a/webkit/glue/weburlloader_impl.cc b/webkit/glue/weburlloader_impl.cc
index 8884bdc..510be0e 100644
--- a/webkit/glue/weburlloader_impl.cc
+++ b/webkit/glue/weburlloader_impl.cc
@@ -167,8 +167,13 @@ void PopulateURLResponse(
// pass it to GetSuggestedFilename.
std::string value;
if (headers->EnumerateHeader(NULL, "content-disposition", &value)) {
- response->setSuggestedFileName(WideToUTF16Hack(
- net::GetSuggestedFilename(url, value, "", std::wstring())));
+#if defined(OS_WIN)
+ response->setSuggestedFileName(
+ net::GetSuggestedFilename(url, value, "", "").value());
+#else
+ response->setSuggestedFileName(UTF8ToUTF16(
+ net::GetSuggestedFilename(url, value, "", "").value()));
+#endif
}
Time time_val;