[librsvg/librsvg-2.44] Fix memory leak in handle
- From: Federico Mena Quintero <federico src gnome org>
 
- To: commits-list gnome org
 
- Cc: 
 
- Subject: [librsvg/librsvg-2.44] Fix memory leak in handle
 
- Date: Tue, 13 Nov 2018 20:40:53 +0000 (UTC)
 
commit c81739dc1049218e44283d65132af7d8d1a66386
Author: Benedikt Heine <bebe bebehei de>
Date:   Mon Nov 12 06:17:02 2018 +0100
    Fix memory leak in handle
 gdk-pixbuf-loader/io-svg.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
---
diff --git a/gdk-pixbuf-loader/io-svg.c b/gdk-pixbuf-loader/io-svg.c
index 0e7bf13d..06b5aef9 100644
--- a/gdk-pixbuf-loader/io-svg.c
+++ b/gdk-pixbuf-loader/io-svg.c
@@ -154,8 +154,11 @@ gdk_pixbuf__svg_image_stop_load (gpointer data, GError **error)
                 return FALSE;
         }
 
-        if (!rsvg_handle_close (context->handle, error))
+        if (!rsvg_handle_close (context->handle, error)) {
+                g_object_unref (context->handle);
+                g_free (context);
                 return FALSE;
+        }
 
         pixbuf = rsvg_handle_get_pixbuf (context->handle);
 
[
Date Prev][
Date Next]   [
Thread Prev][
Thread Next]   
[
Thread Index]
[
Date Index]
[
Author Index]