Title: [152483] trunk/Source/WebKit/gtk
- Revision
- 152483
- Author
- [email protected]
- Date
- 2013-07-08 22:39:16 -0700 (Mon, 08 Jul 2013)
Log Message
[GTK] webkit_set_cache_model is not turning the cache off
https://bugs.webkit.org/show_bug.cgi?id=118345
Reviewed by Gustavo Noronha Silva.
Our documentation says that WEBKIT_CACHE_MODEL_DOCUMENT_VIEWER
disables the cache completely, but we are only setting the cache
capacities to 0. Cache capacities are not checked when resources
are added to the cache, but when it's pruned. To disable the cache
we need to call MemoryCache::setDisabled explicitly.
* webkit/webkitglobals.cpp:
(webkit_set_cache_model): Disable the cache when min dead, max
dead and total capacities are all set to 0.
Modified Paths
Diff
Modified: trunk/Source/WebKit/gtk/ChangeLog (152482 => 152483)
--- trunk/Source/WebKit/gtk/ChangeLog 2013-07-09 05:21:51 UTC (rev 152482)
+++ trunk/Source/WebKit/gtk/ChangeLog 2013-07-09 05:39:16 UTC (rev 152483)
@@ -1,3 +1,20 @@
+2013-07-08 Carlos Garcia Campos <[email protected]>
+
+ [GTK] webkit_set_cache_model is not turning the cache off
+ https://bugs.webkit.org/show_bug.cgi?id=118345
+
+ Reviewed by Gustavo Noronha Silva.
+
+ Our documentation says that WEBKIT_CACHE_MODEL_DOCUMENT_VIEWER
+ disables the cache completely, but we are only setting the cache
+ capacities to 0. Cache capacities are not checked when resources
+ are added to the cache, but when it's pruned. To disable the cache
+ we need to call MemoryCache::setDisabled explicitly.
+
+ * webkit/webkitglobals.cpp:
+ (webkit_set_cache_model): Disable the cache when min dead, max
+ dead and total capacities are all set to 0.
+
2013-07-08 Brian Holt <[email protected]>
[GTK] FrameLoaderClient: Refactor naked pointers to use smart pointers
Modified: trunk/Source/WebKit/gtk/webkit/webkitglobals.cpp (152482 => 152483)
--- trunk/Source/WebKit/gtk/webkit/webkitglobals.cpp 2013-07-09 05:21:51 UTC (rev 152482)
+++ trunk/Source/WebKit/gtk/webkit/webkitglobals.cpp 2013-07-09 05:39:16 UTC (rev 152483)
@@ -156,6 +156,8 @@
g_return_if_reached();
}
+ bool disableCache = !cacheMinDeadCapacity && !cacheMaxDeadCapacity && !cacheTotalCapacity;
+ memoryCache()->setDisabled(disableCache);
memoryCache()->setCapacities(cacheMinDeadCapacity, cacheMaxDeadCapacity, cacheTotalCapacity);
memoryCache()->setDeadDecodedDataDeletionInterval(deadDecodedDataDeletionInterval);
pageCache()->setCapacity(pageCacheCapacity);
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes