summaryrefslogtreecommitdiff
path: root/content/llcache.c
diff options
context:
space:
mode:
Diffstat (limited to 'content/llcache.c')
-rw-r--r--content/llcache.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/content/llcache.c b/content/llcache.c
index b8dc24df0..c786ad02d 100644
--- a/content/llcache.c
+++ b/content/llcache.c
@@ -891,8 +891,15 @@ static nserror llcache_object_destroy(llcache_object *object)
LLCACHE_LOG(("Destroying object %p", object));
+ if (object->source_data != NULL) {
+ if (object->store_state == LLCACHE_STATE_DISC) {
+ guit->llcache->release(object->url, BACKING_STORE_NONE);
+ } else {
+ free(object->source_data);
+ }
+ }
+
nsurl_unref(object->url);
- free(object->source_data);
if (object->fetch.fetch != NULL) {
fetch_abort(object->fetch.fetch);