From f109546b2d59bb5d51dc645cd3454334dd984e87 Mon Sep 17 00:00:00 2001 From: Daniel Carl Date: Fri, 15 Apr 2016 13:08:29 +0200 Subject: [PATCH] Write soup cache to disk after each page load. This allows new instances of vimb to pickup latest cache entries. --- src/main.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/main.c b/src/main.c index 5317404..6dbc6f6 100644 --- a/src/main.c +++ b/src/main.c @@ -811,6 +811,12 @@ static void webview_load_status_cb(WebKitWebView *view, GParamSpec *pspec) if (strncmp(uri, "about:", 6)) { history_add(HISTORY_URL, uri, webkit_web_view_get_title(view)); } +#ifdef FEATURE_SOUP_CACHE + /* Make sure the caches are written to file to be picked up by new + * browser instance. */ + soup_cache_flush(vb.config.soup_cache); + soup_cache_dump(vb.config.soup_cache); +#endif break; case WEBKIT_LOAD_FAILED: -- 2.20.1