summaryrefslogtreecommitdiff
path: root/content/no_backing_store.c
diff options
context:
space:
mode:
authorVincent Sanders <vince@kyllikki.org>2014-11-20 22:28:19 +0000
committerVincent Sanders <vince@kyllikki.org>2014-11-20 22:28:19 +0000
commiteb8740675823a364f319decd3b6e0615607fdc6b (patch)
tree0a38856e08cb0261fe17be2ad5f8e4fdc390251a /content/no_backing_store.c
parent75623179aa7a0259477ef93dcd2a3562c4884c74 (diff)
downloadnetsurf-eb8740675823a364f319decd3b6e0615607fdc6b.tar.gz
netsurf-eb8740675823a364f319decd3b6e0615607fdc6b.tar.bz2
update entry points to backing store ready for allowing differing object lifetimes
Diffstat (limited to 'content/no_backing_store.c')
-rw-r--r--content/no_backing_store.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/content/no_backing_store.c b/content/no_backing_store.c
index 192101522..917d68a11 100644
--- a/content/no_backing_store.c
+++ b/content/no_backing_store.c
@@ -57,12 +57,30 @@ static nserror invalidate(nsurl *url)
return NSERROR_NOT_FOUND;
}
+/**
+ * release a previously fetched or stored memory object.
+ *
+ * if the BACKING_STORE_ALLOC flag was used with the fetch or
+ * store operation for this url the returned storage is
+ * unreferenced. When the reference count drops to zero the
+ * storage is released.
+ *
+ * @param url The url is used as the unique primary key to invalidate.
+ * @param[in] flags The flags to control how the object data is released.
+ * @return NSERROR_OK on success or error code on faliure.
+ */
+static nserror release(nsurl *url, enum backing_store_flags flags)
+{
+ return NSERROR_NOT_FOUND;
+}
+
static struct gui_llcache_table llcache_table = {
.initialise = initialise,
.finalise = finalise,
.store = store,
.fetch = fetch,
.invalidate = invalidate,
+ .release = release,
};
struct gui_llcache_table *null_llcache_table = &llcache_table;