[Pkg-utopia-commits] r184 - in packages/hal/trunk/debian: . patches

Sjoerd Simons sjoerd@costa.debian.org
Tue, 15 Feb 2005 11:18:41 +0100


Author: sjoerd
Date: 2005-02-15 11:18:40 +0100 (Tue, 15 Feb 2005)
New Revision: 184

Added:
   packages/hal/trunk/debian/patches/no_sysdevice.patch
Modified:
   packages/hal/trunk/debian/changelog
Log:
Don\'t die when a sysfs path doesn't exist (anymore)

Modified: packages/hal/trunk/debian/changelog
===================================================================
--- packages/hal/trunk/debian/changelog	2005-02-12 19:37:34 UTC (rev 183)
+++ packages/hal/trunk/debian/changelog	2005-02-15 10:18:40 UTC (rev 184)
@@ -4,9 +4,12 @@
     + Updated. Enable the quiet option for vfat volumes (Closes: #292661)
   * debian/hal.dbus.init
     + Show a warning message when trying to start with an unsupported kernel
-      (Closes: #292644) 
+      (Closes: #292644)
+  * debian/patches/no_sysdevice.path
+    + Don't die when a device doesn't have a sysfs path when finalizing the
+      class device. (Closes: #293630)
 
- -- Sjoerd Simons <sjoerd@debian.org>  Tue,  8 Feb 2005 16:58:24 +0100
+ -- Sjoerd Simons <sjoerd@debian.org>  Tue, 15 Feb 2005 10:15:29 +0100
 
 hal (0.4.7-1) unstable; urgency=medium
 

Added: packages/hal/trunk/debian/patches/no_sysdevice.patch
===================================================================
--- packages/hal/trunk/debian/patches/no_sysdevice.patch	2005-02-12 19:37:34 UTC (rev 183)
+++ packages/hal/trunk/debian/patches/no_sysdevice.patch	2005-02-15 10:18:40 UTC (rev 184)
@@ -0,0 +1,18 @@
+diff -ruN hal-0.4.7-old/hald/linux/class_device.c hal-0.4.7/hald/linux/class_device.c
+--- hal-0.4.7-old/hald/linux/class_device.c	2004-12-01 04:39:01.000000000 +0100
++++ hal-0.4.7/hald/linux/class_device.c	2005-02-15 10:10:17.060885680 +0100
+@@ -447,9 +447,12 @@
+ 	sysfs_path = hal_device_property_get_string (d, ".udev.sysfs_path");
+ 	assert (sysfs_path != NULL);
+ 	class_device = sysfs_open_class_device_path (sysfs_path);
+-	if (class_device == NULL)
+-		DIE (("Coulnd't get sysfs class device object for path %s", 
++	if (class_device == NULL) {
++		HAL_WARNING (("Coulnd't get sysfs class device object for path %s", 
+ 		      sysfs_path));
++		hal_device_store_remove (hald_get_tdl (), d);
++		return;
++	}
+ 	self->pre_process (self, d, sysfs_path, class_device);
+ 	sysfs_close_class_device (class_device);
+