summaryrefslogtreecommitdiff
path: root/content/llcache.c
diff options
context:
space:
mode:
Diffstat (limited to 'content/llcache.c')
-rw-r--r--content/llcache.c20
1 files changed, 7 insertions, 13 deletions
diff --git a/content/llcache.c b/content/llcache.c
index 3fbe5ec0b..f658380ab 100644
--- a/content/llcache.c
+++ b/content/llcache.c
@@ -23,17 +23,19 @@
#include <stdlib.h>
#include <string.h>
#include <time.h>
-
#include <curl/curl.h>
-#include "content/fetch.h"
-#include "content/llcache.h"
-#include "content/urldb.h"
#include "utils/corestrings.h"
#include "utils/log.h"
#include "utils/messages.h"
#include "utils/nsurl.h"
#include "utils/utils.h"
+#include "utils/schedule.h"
+#include "desktop/gui_factory.h"
+
+#include "content/fetch.h"
+#include "content/llcache.h"
+#include "content/urldb.h"
/** Define to enable tracing of llcache operations. */
#undef LLCACHE_TRACE
@@ -1638,14 +1640,6 @@ static nserror llcache_fetch_ssl_error(llcache_object *object)
#define LLCACHE_MIN_DISC_LIFETIME 3600
#define LLCACHE_MAX_DISC_BANDWIDTH (512*1024)
-static nserror write_llcache_file(nsurl *url,
- int remaining,
- const uint8_t *data,
- size_t datalen)
-{
- LOG(("Writing cache file for url:%s", nsurl_access(url)));
- return NSERROR_OK;
-}
/**
* possibly push objects to disc cache.
@@ -1672,7 +1666,7 @@ static void llcache_discwrite(void *p)
(object->store_state == LLCACHE_STORE_RAM) &&
(remaining_lifetime > LLCACHE_MIN_DISC_LIFETIME)) {
/* ok found an object to write */
- ret = write_llcache_file(object->url,
+ ret = guit->llcache->persist(object->url,
remaining_lifetime,
object->source_data,
object->source_len);