hal: Branch 'master'

David Zeuthen david at kemper.freedesktop.org
Tue Jul 17 22:11:20 EEST 2007


 hald/linux/osspec.c |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletion(-)

New commits:
diff-tree 69881e0cd2b400012ce28eef887bdf0dd0d2526b (from bfec0c1df2d3f55851e3774af38ee8e20aab0a9c)
Author: David Zeuthen <davidz at redhat.com>
Date:   Tue Jul 17 15:11:23 2007 -0400

    avoid emitting hotplug events during coldplug

diff --git a/hald/linux/osspec.c b/hald/linux/osspec.c
index 6227e34..0030072 100644
--- a/hald/linux/osspec.c
+++ b/hald/linux/osspec.c
@@ -68,6 +68,8 @@
 static char *hal_sysfs_path;
 static char *hal_proc_path;
 
+static gboolean hald_done_synthesizing_coldplug = FALSE;
+
 const gchar *
 get_hal_sysfs_path (void)
 {
@@ -403,8 +405,9 @@ computer_callouts_add_done (HalDevice *d
 void
 hotplug_queue_now_empty (void)
 {
-	if (hald_is_initialising)
+	if (hald_is_initialising && hald_done_synthesizing_coldplug) {
 		osspec_probe_done ();
+        }
 }
 
 
@@ -432,6 +435,8 @@ computer_probing_helper_done (HalDevice 
 	}
 	HAL_INFO (("Done synthesizing events"));
 
+        hald_done_synthesizing_coldplug = TRUE;
+
 	/* we try again to match again on computer, now we have done coldplug
 	 * and completed probing. In an ideal world, we would do this before
 	 * _and_ after the coldplug, but this seems to work well. */


More information about the hal-commit mailing list