[Pkg-xfce-commits] r2448 - in goodies/ristretto/debian: . patches

corsac at alioth.debian.org corsac at alioth.debian.org
Wed Oct 22 06:30:35 UTC 2008


Author: corsac
Date: 2008-10-22 06:30:34 +0000 (Wed, 22 Oct 2008)
New Revision: 2448

Added:
   goodies/ristretto/debian/patches/
   goodies/ristretto/debian/patches/01_plug-memleak.patch
Modified:
   goodies/ristretto/debian/changelog
   goodies/ristretto/debian/rules
Log:
* debian/patches:
  - 01_plug-memleak added, fixes a huge memleak when using autoreload.
    (r4842, Xfce4 #4508)
* debian/rules:
  - add simple-patchsys rule.

Modified: goodies/ristretto/debian/changelog
===================================================================
--- goodies/ristretto/debian/changelog	2008-10-21 22:21:24 UTC (rev 2447)
+++ goodies/ristretto/debian/changelog	2008-10-22 06:30:34 UTC (rev 2448)
@@ -1,9 +1,17 @@
 ristretto (0.0.20-3) UNRELEASED; urgency=low
 
+  [ Stefan Ott ]
   * debian/control: update e-mail address
 
- -- Stefan Ott <stefan at ott.net>  Sat, 12 Jul 2008 03:27:57 +0200
+  [ Yves-Alexis Perez ]
+  * debian/patches:
+    - 01_plug-memleak added, fixes a huge memleak when using autoreload.
+      (r4842, Xfce4 #4508)
+  * debian/rules:
+    - add simple-patchsys rule.
 
+ -- Yves-Alexis Perez <corsac at debian.org>  Wed, 22 Oct 2008 08:04:09 +0200
+
 ristretto (0.0.20-2) unstable; urgency=low
 
   * debian/rules: call dh_desktop so mime desktop database gets updated.

Added: goodies/ristretto/debian/patches/01_plug-memleak.patch
===================================================================
--- goodies/ristretto/debian/patches/01_plug-memleak.patch	                        (rev 0)
+++ goodies/ristretto/debian/patches/01_plug-memleak.patch	2008-10-22 06:30:34 UTC (rev 2448)
@@ -0,0 +1,87 @@
+commit f261483c28c878c1df9a6bb9b9ad7994b86e0829
+Author: stephan <stephan at 6bd62a53-d0f8-0310-92b8-b27fb566919e>
+Date:   Wed Oct 22 05:42:19 2008 +0000
+
+    Plug memory leak (I think) and fix compile-warning
+    
+    
+    
+    git-svn-id: http://svn.xfce.org/svn/goodies/ristretto/trunk@5744 6bd62a53-d0f8-0310-92b8-b27fb566919e
+
+diff --git a/src/main_window.c b/src/main_window.c
+index a18c765..b3d69c3 100644
+--- a/src/main_window.c
++++ b/src/main_window.c
+@@ -438,8 +438,7 @@ rstto_main_window_init(RsttoMainWindow *window)
+ 
+         g_snprintf(selection_name, 100, XFDESKTOP_SELECTION_FMT, xscreen);
+ 
+-        Window root_window = GDK_ROOT_WINDOW();
+         Atom xfce_desktop_atom = XInternAtom (gdk_display, "XFCE_DESKTOP_WINDOW", False);
+         Atom xfce_selection_atom = XInternAtom (gdk_display, selection_name, False);
+         if((XGetSelectionOwner(GDK_DISPLAY(), xfce_selection_atom)))
+         {
+@@ -1215,6 +1214,7 @@ cb_rstto_main_window_set_wallpaper(GtkWidget *widget, RsttoMainWindow *window)
+                 }
+                 g_free(image_path_prop);
+                 g_free(image_show_prop);
++                g_free(image_style_prop);
+                 g_object_unref(xfdesktop_channel);
+             }
+             break;
+diff --git a/src/navigator.c b/src/navigator.c
+index 179051f..57ff83e 100644
+--- a/src/navigator.c
++++ b/src/navigator.c
+@@ -1156,6 +1156,11 @@ rstto_navigator_entry_load_image (RsttoNavigatorEntry *entry, gboolean empty_cac
+     }
+     if ((entry->loader == NULL) && ((empty_cache == TRUE ) || entry->src_pixbuf == NULL))
+     {
++        if (entry->src_pixbuf)
++        {
++            gdk_pixbuf_unref(entry->src_pixbuf);
++            entry->src_pixbuf = NULL;
++        }
+         entry->loader = gdk_pixbuf_loader_new();
+ 
+         g_signal_connect(entry->loader, "area-prepared", G_CALLBACK(cb_rstto_navigator_entry_area_prepared), entry);
+@@ -1272,14 +1277,14 @@ cb_rstto_navigator_entry_area_prepared (GdkPixbufLoader *loader, RsttoNavigatorE
+ static void
+ cb_rstto_navigator_entry_closed (GdkPixbufLoader *loader, RsttoNavigatorEntry *entry)
+ {
++    GdkPixbuf *pixbuf = NULL;
++
+     if (entry->src_pixbuf)
+     {
+         gdk_pixbuf_unref(entry->src_pixbuf);
+         entry->src_pixbuf = NULL;
+     }
+ 
+-    GdkPixbuf *pixbuf = NULL;
+-
+     if (entry->iter)
+     {
+         pixbuf = gdk_pixbuf_animation_iter_get_pixbuf(entry->iter);
+@@ -1302,11 +1307,14 @@ cb_rstto_navigator_entry_closed (GdkPixbufLoader *loader, RsttoNavigatorEntry *e
+     if (pixbuf != NULL)
+     {
+         entry->src_pixbuf = gdk_pixbuf_rotate_simple(pixbuf, rstto_navigator_entry_get_rotation(entry));
++        gdk_pixbuf_unref(pixbuf);
++        pixbuf = NULL;
+         if (rstto_navigator_entry_get_flip(entry, FALSE))
+         {
+             pixbuf = entry->src_pixbuf;
+             entry->src_pixbuf = gdk_pixbuf_flip(pixbuf, FALSE);
+             gdk_pixbuf_unref(pixbuf);
++            pixbuf = NULL;
+         }
+ 
+         if (rstto_navigator_entry_get_flip(entry, TRUE))
+@@ -1314,6 +1322,7 @@ cb_rstto_navigator_entry_closed (GdkPixbufLoader *loader, RsttoNavigatorEntry *e
+             pixbuf = entry->src_pixbuf;
+             entry->src_pixbuf = gdk_pixbuf_flip(pixbuf, TRUE);
+             gdk_pixbuf_unref(pixbuf);
++            pixbuf = NULL;
+         }
+         g_signal_emit(G_OBJECT(entry->navigator), rstto_navigator_signals[RSTTO_NAVIGATOR_SIGNAL_ENTRY_MODIFIED], 0, entry, NULL);
+     }

Modified: goodies/ristretto/debian/rules
===================================================================
--- goodies/ristretto/debian/rules	2008-10-21 22:21:24 UTC (rev 2447)
+++ goodies/ristretto/debian/rules	2008-10-22 06:30:34 UTC (rev 2448)
@@ -1,5 +1,6 @@
 #!/usr/bin/make -f
 include /usr/share/cdbs/1/rules/debhelper.mk
+include /usr/share/cdbs/1/rules/simple-patchsys.mk
 include /usr/share/cdbs/1/class/autotools.mk
 
 DEB_INSTALL_MANPAGES_ristretto := debian/ristretto.1




More information about the Pkg-xfce-commits mailing list