[Pkg-utopia-commits] r811 - in packages/unstable/networkmanager/debian: . patches

Michael Biebl mbiebl-guest at costa.debian.org
Fri May 5 16:59:13 UTC 2006


Author: mbiebl-guest
Date: 2006-05-05 16:59:12 +0000 (Fri, 05 May 2006)
New Revision: 811

Added:
   packages/unstable/networkmanager/debian/patches/07-libnm_glib_reconnect_dbus.patch
Modified:
   packages/unstable/networkmanager/debian/changelog
   packages/unstable/networkmanager/debian/control
Log:
- Standards-Version 3.7.2
- Make libnm_glib wait between connection attempts to dbus (07-libnm_glib_reconnect_dbus.patch)


Modified: packages/unstable/networkmanager/debian/changelog
===================================================================
--- packages/unstable/networkmanager/debian/changelog	2006-05-05 08:48:16 UTC (rev 810)
+++ packages/unstable/networkmanager/debian/changelog	2006-05-05 16:59:12 UTC (rev 811)
@@ -1,12 +1,15 @@
 network-manager (0.6.2-2) unstable; urgency=low
 
-  * More integration work. 
+  * More integration work.
     Added network-manager-dispatcher.script and 06-dispatch_more_events.patch.
     This way the scripts in /etc/networks/if-*.d/ are called properly by
     NetworkManagerDispatcher.
     Thanks to the Ubuntu devs for this work!
+  * Added 07-libnm_glib_reconnect_dbus.patch which makes libnm_glib sleep between
+    unsuccessful connection attempts to dbus. (Closes: #366010)
+  * Bumped Standards-Version to 3.7.2, no further changes required.
 
- -- Michael Biebl <biebl at teco.edu>  Wed,  5 Apr 2006 18:52:57 +0200
+ -- Michael Biebl <biebl at teco.edu>  Fri,  5 May 2006 18:01:47 +0200
 
 network-manager (0.6.2-1) unstable; urgency=low
 

Modified: packages/unstable/networkmanager/debian/control
===================================================================
--- packages/unstable/networkmanager/debian/control	2006-05-05 08:48:16 UTC (rev 810)
+++ packages/unstable/networkmanager/debian/control	2006-05-05 16:59:12 UTC (rev 811)
@@ -4,7 +4,7 @@
 Maintainer: Riccardo Setti <giskard at autistici.org>
 Uploaders: Michael Biebl <biebl at teco.edu>
 Build-Depends: debhelper (>= 5), cdbs, gnome-common, intltool, libgnome-keyring-dev, libdbus-glib-1-dev (>= 0.60), libiw-dev(>= 27+28pre9), libgnomeui-dev, libpanel-applet2-dev, libglade2-dev, libgconf2-dev, libhal-dev (>= 0.5.0), libnl-dev (>= 0.99+1.0.svn21), libnotify-dev (>= 0.3), docbook-to-man
-Standards-Version: 3.6.2
+Standards-Version: 3.7.2
 
 Package: network-manager
 Architecture: any

Added: packages/unstable/networkmanager/debian/patches/07-libnm_glib_reconnect_dbus.patch
===================================================================
--- packages/unstable/networkmanager/debian/patches/07-libnm_glib_reconnect_dbus.patch	2006-05-05 08:48:16 UTC (rev 810)
+++ packages/unstable/networkmanager/debian/patches/07-libnm_glib_reconnect_dbus.patch	2006-05-05 16:59:12 UTC (rev 811)
@@ -0,0 +1,65 @@
+Index: gnome/libnm_glib/libnm_glib.c
+===================================================================
+RCS file: /cvs/gnome/NetworkManager/gnome/libnm_glib/libnm_glib.c,v
+retrieving revision 1.11
+diff -u -p -r1.11 libnm_glib.c
+--- gnome/libnm_glib/libnm_glib.c	21 Feb 2006 06:25:50 -0000	1.11
++++ gnome/libnm_glib/libnm_glib.c	5 May 2006 15:35:55 -0000
+@@ -39,6 +39,7 @@ struct libnm_glib_ctx
+ 	GMainLoop *		g_main_loop;
+ 	DBusConnection	*	dbus_con;
+ 	guint			dbus_watcher;
++	guint			dbus_watch_interval;
+ 	gboolean			thread_done;
+ 	gboolean			thread_inited;
+ 
+@@ -347,14 +348,29 @@ libnm_glib_dbus_watcher (gpointer user_d
+ 
+ 	g_return_val_if_fail (ctx != NULL, FALSE);
+ 
++	ctx->dbus_watcher = 0;
++
+ 	if (!ctx->dbus_con)
+ 		ctx->dbus_con = libnm_glib_dbus_init ((gpointer)ctx, ctx->g_main_ctx);
+ 
+ 	if (ctx->dbus_con)
+-		return (FALSE);	/* Don't reschedule ourselves if we have a connection to dbus */
++	{
++		/* Get NM's state right away after we reconnect */
++		libnm_glib_get_nm_state (ctx);
++		ctx->dbus_watch_interval = 1000;
++	}
++	else
++	{
++		/* Wait 3 seconds longer each time we fail to reconnect to dbus,
++		 * with a maximum wait of one minute.
++		 */
++		ctx->dbus_watch_interval = MIN(ctx->dbus_watch_interval + 3000, 60000); 
+ 
+-	/* Reschule ourselves if we _still_ don't have a connection to dbus */
+-	return (TRUE);
++		/* Reschule ourselves if we _still_ don't have a connection to dbus */
++		libnm_glib_schedule_dbus_watcher (ctx);
++	}
++
++	return FALSE;
+ }
+ 
+ 
+@@ -372,7 +388,7 @@ libnm_glib_schedule_dbus_watcher (libnm_
+ 
+ 	if (ctx->dbus_watcher == 0)
+ 	{
+-		GSource	*source = g_idle_source_new ();
++		GSource *	source = g_timeout_source_new (ctx->dbus_watch_interval);
+ 		g_source_set_callback (source, libnm_glib_dbus_watcher, (gpointer) ctx, NULL);
+ 		ctx->dbus_watcher = g_source_attach (source, ctx->g_main_ctx);
+ 		g_source_unref (source);
+@@ -453,6 +469,7 @@ libnm_glib_ctx_new (void)
+ 		goto error;
+ 	if (!(ctx->callbacks_lock = g_mutex_new ()))
+ 		goto error;
++	ctx->dbus_watch_interval = 1000;
+ 
+ 	return ctx;
+ 




More information about the Pkg-utopia-commits mailing list