summaryrefslogtreecommitdiff
path: root/libsoup/soup-cache.c
diff options
context:
space:
mode:
authorXan Lopez <xlopez@igalia.com>2011-04-23 12:40:55 -0700
committerXan Lopez <xlopez@igalia.com>2011-04-25 10:04:25 -0700
commit838f19a23005096b43eddaca51205381f9becdbe (patch)
tree7638087f868a1f037f3f3bc8e26055c12ddf8bbf /libsoup/soup-cache.c
parent4fccc7a2464075e83e572a7907cc11831cddd872 (diff)
downloadlibsoup-838f19a23005096b43eddaca51205381f9becdbe.tar.gz
soup-cache: plug leak
We are leaking a GFile per cache response. https://bugzilla.gnome.org/show_bug.cgi?id=648521
Diffstat (limited to 'libsoup/soup-cache.c')
-rw-r--r--libsoup/soup-cache.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libsoup/soup-cache.c b/libsoup/soup-cache.c
index 4812f469..5b64575c 100644
--- a/libsoup/soup-cache.c
+++ b/libsoup/soup-cache.c
@@ -1035,7 +1035,8 @@ soup_cache_send_response (SoupCache *cache, SoupMessage *msg)
were the file was no longer there (for example files
removed without notifying the cache */
file = g_file_new_for_path (entry->filename);
- stream = (GInputStream *)g_file_read (file, NULL, NULL);
+ stream = G_INPUT_STREAM (g_file_read (file, NULL, NULL));
+ g_object_unref (file);
return stream;
}