[libsoup] soup-message-io: fix reference leak



commit dbc41f65f80336052f57a2e3cfb48163a2a6185a
Author: Ray Strode <rstrode redhat com>
Date:   Mon May 14 13:51:43 2012 -0400

    soup-message-io: fix reference leak
    
    io_run_until forgets to release a reference it takes
    in a cancellation error path.
    
    This commit fixes that.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=676038

 libsoup/soup-message-io.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
---
diff --git a/libsoup/soup-message-io.c b/libsoup/soup-message-io.c
index 145d809..455265e 100644
--- a/libsoup/soup-message-io.c
+++ b/libsoup/soup-message-io.c
@@ -855,6 +855,7 @@ io_run_until (SoupMessage *msg,
 		g_object_unref (msg);
 		return FALSE;
 	} else if (g_cancellable_set_error_if_cancelled (cancellable, error)) {
+		g_object_unref (msg);
 		return FALSE;
 	} else if (priv->io_data != io) {
 		g_set_error_literal (error, G_IO_ERROR,



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]