REGRESSION(r185262): [EFL] Modify legacyPlatformDefaultNetworkCacheDirectory() accord...
authorgyuyoung.kim@webkit.org <gyuyoung.kim@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 8 Jun 2015 10:45:05 +0000 (10:45 +0000)
committergyuyoung.kim@webkit.org <gyuyoung.kim@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 8 Jun 2015 10:45:05 +0000 (10:45 +0000)
https://bugs.webkit.org/show_bug.cgi?id=145752

Reviewed by Carlos Garcia Campos.

EFL port needs to add different prefix for network cache directory since r185262.
Modify it basedon GTK port fix.

* UIProcess/efl/WebProcessPoolEfl.cpp:
(WebKit::WebProcessPool::legacyPlatformDefaultNetworkCacheDirectory):

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

Source/WebKit2/ChangeLog
Source/WebKit2/UIProcess/efl/WebProcessPoolEfl.cpp

index bcd9679..650aff3 100644 (file)
@@ -1,3 +1,16 @@
+2015-06-08  Gyuyoung Kim  <gyuyoung.kim@webkit.org>
+
+        REGRESSION(r185262): [EFL] Modify legacyPlatformDefaultNetworkCacheDirectory() according to network cache
+        https://bugs.webkit.org/show_bug.cgi?id=145752
+
+        Reviewed by Carlos Garcia Campos.
+
+        EFL port needs to add different prefix for network cache directory since r185262.
+        Modify it basedon GTK port fix.
+
+        * UIProcess/efl/WebProcessPoolEfl.cpp:
+        (WebKit::WebProcessPool::legacyPlatformDefaultNetworkCacheDirectory):
+
 2015-06-07  Carlos Garcia Campos  <cgarcia@igalia.com>
 
         REGRESSION(r185262): [GTK] webkit_web_context_set_disk_cache_directory() doesn't work after r185262
index a9bb224..646aaca 100644 (file)
@@ -128,7 +128,18 @@ String WebProcessPool::legacyPlatformDefaultMediaKeysStorageDirectory()
 
 String WebProcessPool::legacyPlatformDefaultNetworkCacheDirectory()
 {
-    return String::fromUTF8(efreet_cache_home_get()) + "/WebKitEfl";
+#if ENABLE(NETWORK_CACHE)
+    static const char networkCacheSubdirectory[] = "WebKitCache";
+#else
+    static const char networkCacheSubdirectory[] = "webkit";
+#endif
+
+    StringBuilder diskCacheDirectory;
+    diskCacheDirectory.append(efreet_cache_home_get());
+    diskCacheDirectory.appendLiteral("/");
+    diskCacheDirectory.append(networkCacheSubdirectory);
+
+    return diskCacheDirectory.toString();
 }
 
 void WebProcessPool::setIgnoreTLSErrors(bool ignoreTLSErrors)