[libsoup] soup-cache: plug leak
- From: Xan Lopez <xan src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libsoup] soup-cache: plug leak
- Date: Mon, 25 Apr 2011 17:04:48 +0000 (UTC)
commit 838f19a23005096b43eddaca51205381f9becdbe
Author: Xan Lopez <xlopez igalia com>
Date: Sat Apr 23 12:40:55 2011 -0700
soup-cache: plug leak
We are leaking a GFile per cache response.
https://bugzilla.gnome.org/show_bug.cgi?id=648521
libsoup/soup-cache.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/libsoup/soup-cache.c b/libsoup/soup-cache.c
index 4812f46..5b64575 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;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]