[mutter] MetaBackgroundImage: free the GdkPixbuf after creating a texture



commit b7355716885b8098107db16f633e230cd67f53bf
Author: Owen W. Taylor <otaylor fishsoup net>
Date:   Mon Sep 29 21:01:50 2014 -0400

    MetaBackgroundImage: free the GdkPixbuf after creating a texture
    
    The GdkPixbuf used to load a texture was never freed.

 src/compositor/meta-background-image.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/src/compositor/meta-background-image.c b/src/compositor/meta-background-image.c
index 1f32f98..af66755 100644
--- a/src/compositor/meta-background-image.c
+++ b/src/compositor/meta-background-image.c
@@ -185,6 +185,9 @@ file_loaded (GObject      *source_object,
   image->texture = texture;
 
 out:
+  if (pixbuf != NULL)
+    g_object_unref (pixbuf);
+
   image->loaded = TRUE;
   g_signal_emit (image, signals[LOADED], 0);
 }


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