r11169 - in /packages/unstable/loudmouth/debian: changelog patches/01_fix_double_freeaddrinfo.patch patches/01_free_callback.patch

daf at users.alioth.debian.org daf at users.alioth.debian.org
Mon May 28 13:27:11 UTC 2007


Author: daf
Date: Mon May 28 13:27:11 2007
New Revision: 11169

URL: http://svn.debian.org/wsvn/pkg-gnome/?sc=1&rev=11169
Log:
add patches

Added:
    packages/unstable/loudmouth/debian/patches/01_fix_double_freeaddrinfo.patch
    packages/unstable/loudmouth/debian/patches/01_free_callback.patch
Modified:
    packages/unstable/loudmouth/debian/changelog

Modified: packages/unstable/loudmouth/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-gnome/packages/unstable/loudmouth/debian/changelog?rev=11169&op=diff
==============================================================================
--- packages/unstable/loudmouth/debian/changelog (original)
+++ packages/unstable/loudmouth/debian/changelog Mon May 28 13:27:11 2007
@@ -1,11 +1,17 @@
 loudmouth (1.2.1-2) UNRELEASED; urgency=low
 
+  [ Loic Minier ]
   * Fix description of the -dbg package.
   * Wrap build-deps and deps.
   * Use http://ftp.imendio.com/pub/imendio/loudmouth/src in copyright.
   * Track all versions in watch file.
 
- -- Loic Minier <lool at dooz.org>  Mon, 30 Apr 2007 12:01:56 +0200
+  [ Dafydd Harries ]
+  * Add debian/patches/01_fix_double_freeaddrinfo.patch, to fix double free
+    crash.
+  * Add debian/patches/01_free_callback.patch, to fix memory leak.
+
+ -- Dafydd Harries <daf at debian.org>  Mon, 28 May 2007 14:24:36 +0100
 
 loudmouth (1.2.1-1) unstable; urgency=low
 

Added: packages/unstable/loudmouth/debian/patches/01_fix_double_freeaddrinfo.patch
URL: http://svn.debian.org/wsvn/pkg-gnome/packages/unstable/loudmouth/debian/patches/01_fix_double_freeaddrinfo.patch?rev=11169&op=file
==============================================================================
--- packages/unstable/loudmouth/debian/patches/01_fix_double_freeaddrinfo.patch (added)
+++ packages/unstable/loudmouth/debian/patches/01_fix_double_freeaddrinfo.patch Mon May 28 13:27:11 2007
@@ -1,0 +1,55 @@
+Index: loudmouth/lm-connection.c
+===================================================================
+--- loudmouth/lm-connection.c	(revision 8017)
++++ loudmouth/lm-connection.c	(revision 8024)
+@@ -287,6 +287,12 @@
+ 		g_string_free (connection->out_buf, TRUE);
+ 	}
+         
++	if (connection->incoming_source) {
++		g_source_destroy (connection->incoming_source);
++		g_source_unref (connection->incoming_source);
++		connection->incoming_source = NULL;
++	}
++
+         g_free (connection);
+ }
+ 
+@@ -538,9 +544,12 @@
+ 			_lm_utils_free_callback (cb);
+ 		}
+ 		
+-		freeaddrinfo (connect_data->resolved_addrs);
+-		connection->connect_data = NULL;
+-		g_free (connect_data);
++		/* if the user callback called connection_close(), this is already freed */
++		if (connection->connect_data) {
++			freeaddrinfo (connect_data->resolved_addrs);
++			connection->connect_data = NULL;
++			g_free (connect_data);
++		}
+ 	} else {
+ 		/* try to connect to the next host */
+ 		connection_do_connect (connect_data);
+@@ -736,6 +745,10 @@
+ 			return;
+ 		}
+ 	}
++
++	/* source thingie for messages and stuff */
++	connection->incoming_source = connection_create_source (connection);
++	g_source_attach (connection->incoming_source, connection->context);
+ }
+ 
+ static guint
+@@ -900,10 +913,6 @@
+ 		return FALSE;
+ 	}
+ 
+-	/* source thingie for messages and stuff */
+-	connection->incoming_source = connection_create_source (connection);
+-	g_source_attach (connection->incoming_source, connection->context);
+-	
+ 	lm_verbose ("Connecting to: %s:%d\n", 
+ 		    connection->server, connection->port);
+ 

Added: packages/unstable/loudmouth/debian/patches/01_free_callback.patch
URL: http://svn.debian.org/wsvn/pkg-gnome/packages/unstable/loudmouth/debian/patches/01_free_callback.patch?rev=11169&op=file
==============================================================================
--- packages/unstable/loudmouth/debian/patches/01_free_callback.patch (added)
+++ packages/unstable/loudmouth/debian/patches/01_free_callback.patch Mon May 28 13:27:11 2007
@@ -1,0 +1,12 @@
+diff -Nur loudmouth-1.2.1/loudmouth/lm-connection.c loudmouth-1.2.1.new/loudmouth/lm-connection.c
+--- loudmouth-1.2.1/loudmouth/lm-connection.c	2007-05-28 14:08:59.000000000 +0100
++++ loudmouth-1.2.1.new/loudmouth/lm-connection.c	2007-05-28 14:09:23.000000000 +0100
+@@ -1441,7 +1441,7 @@
+ 						           result, cb->user_data);
+ 		}
+ 
+-		_lm_utils_free_callback (connection->open_cb);
++		_lm_utils_free_callback (cb);
+ 	}
+ 	
+ 	return LM_HANDLER_RESULT_REMOVE_MESSAGE;




More information about the pkg-gnome-commits mailing list