diff options
Diffstat (limited to 'gtk/llcache.c')
-rw-r--r-- | gtk/llcache.c | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/gtk/llcache.c b/gtk/llcache.c new file mode 100644 index 000000000..56d6d12ab --- /dev/null +++ b/gtk/llcache.c @@ -0,0 +1,43 @@ +/* + * Copyright 2014 Vincent Sanders <vince@netsurf-browser.org> + * + * This file is part of NetSurf, http://www.netsurf-browser.org/ + * + * NetSurf is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; version 2 of the License. + * + * NetSurf is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + */ + +#include "utils/nsurl.h" +#include "utils/log.h" +#include "desktop/gui.h" + +#include "gtk/llcache.h" + +static nserror +persist(nsurl *url, int remaining, const uint8_t *data, size_t datalen) +{ + LOG(("Writing cache file for url:%s", nsurl_access(url))); + return NSERROR_OK; +} + +static nserror +retrieve(nsurl *url, int *remaining_out, const uint8_t **data_out, size_t *datalen_out) +{ + return NSERROR_NOT_FOUND; +} + +static struct gui_llcache_table llcache_table = { + .persist = persist, + .retrieve = retrieve, +}; + +struct gui_llcache_table *nsgtk_llcache_table = &llcache_table; |