rpms/metacity/devel leaks.patch, NONE, 1.1 string-leak.patch, NONE, 1.1 metacity.spec, 1.162, 1.163

Matthias Clasen mclasen at fedoraproject.org
Fri Sep 19 23:07:01 UTC 2008


Author: mclasen

Update of /cvs/extras/rpms/metacity/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv1048

Modified Files:
	metacity.spec 
Added Files:
	leaks.patch string-leak.patch 
Log Message:
fix memory leaks


leaks.patch:

--- NEW FILE leaks.patch ---
diff -up metacity-2.23.610/src/core/edge-resistance.c.leaks metacity-2.23.610/src/core/edge-resistance.c
--- metacity-2.23.610/src/core/edge-resistance.c.leaks	2008-09-14 22:39:38.000000000 -0400
+++ metacity-2.23.610/src/core/edge-resistance.c	2008-09-14 22:43:28.000000000 -0400
@@ -985,8 +985,8 @@ meta_display_compute_resistance_and_snap
       cur_window_iter = cur_window_iter->next;
     }
   /* Put 'em in bottom to top order */
-  rem_windows       = g_slist_reverse (obscuring_windows);
-  rem_win_stacking  = g_slist_reverse (window_stacking);
+  rem_windows = obscuring_windows = g_slist_reverse (obscuring_windows);
+  rem_win_stacking = window_stacking = g_slist_reverse (window_stacking);
 
   /*
    * 3rd: loop over the windows again, this time getting the edges from

string-leak.patch:

--- NEW FILE string-leak.patch ---
diff -up metacity-2.23.610/src/ui/ui.c.string-leak metacity-2.23.610/src/ui/ui.c
--- metacity-2.23.610/src/ui/ui.c.string-leak	2008-08-18 08:29:07.000000000 -0400
+++ metacity-2.23.610/src/ui/ui.c	2008-09-15 18:05:20.000000000 -0400
@@ -657,10 +657,12 @@ meta_text_property_to_utf8 (Display     
                                           &list);
 
   if (count == 0)
-    return NULL;
-
-  retval = list[0];
-  list[0] = g_strdup (""); /* something to free */
+    retval = NULL;
+  else
+    {
+      retval = list[0];
+      list[0] = g_strdup (""); /* something to free */
+    }
   
   g_strfreev (list);
 


Index: metacity.spec
===================================================================
RCS file: /cvs/extras/rpms/metacity/devel/metacity.spec,v
retrieving revision 1.162
retrieving revision 1.163
diff -u -r1.162 -r1.163
--- metacity.spec	10 Sep 2008 01:20:55 -0000	1.162
+++ metacity.spec	19 Sep 2008 23:06:30 -0000	1.163
@@ -1,12 +1,16 @@
 Summary: Metacity window manager
 Name: metacity
 Version: 2.23.610
-Release: 1%{?dist}
+Release: 2%{?dist}
 URL: http://download.gnome.org/sources/metacity/
 Source0: http://download.gnome.org/sources/metacity/2.23/metacity-%{version}.tar.bz2
 Patch0: default-theme.patch
 # http://bugzilla.gnome.org/show_bug.cgi?id=482354
 Patch1: metacity-2.21.13-dont-move-windows.patch
+# http://bugzilla.gnome.org/show_bug.cgi?id=552303
+Patch2: leaks.patch
+# http://bugzilla.gnome.org/show_bug.cgi?id=552307
+Patch3: string-leak.patch
 
 License: GPLv2+
 Group: User Interface/Desktops
@@ -63,6 +67,8 @@
 %setup -q 
 %patch0 -p1 -b .default-theme
 %patch1 -p0 -b .dont-move-windows
+%patch2 -p1 -b .leaks
+%patch3 -p1 -b .string-leak
 
 %build
 rm -rf $RPM_BUILD_ROOT
@@ -155,6 +161,9 @@
 %{_mandir}/man1/metacity-window-demo.1.gz
 
 %changelog
+* FRi Sep 19 2008 Matthias Clasen <mclasen at redhat.com> - 2.23.610-2
+- Fix some memory leaks
+
 * Tue Sep  9 2008 Matthias Clasen <mclasen at redhat.com> - 2.23.610-1
 - Update to 2.23.610
 




More information about the fedora-extras-commits mailing list