hal/hald/linux2 blockdev.c,1.40,1.41
Danny Kukawka
dkukawka at kemper.freedesktop.org
Tue May 9 13:13:44 PDT 2006
Update of /cvs/hal/hal/hald/linux2
In directory kemper:/tmp/cvs-serv24319/hald/linux2
Modified Files:
blockdev.c
Log Message:
2006-05-09 Danny Kukawka <danny.kukawka at web.de>
* hald/linux2/blockdev.c: (blockdev_refresh_mount_state): Skip stat
nfs mounts. This should solve blocked hald (and failing aplications
which use hal) if there are nfs share mounts with 'stale nfs handle'.
Index: blockdev.c
===================================================================
RCS file: /cvs/hal/hal/hald/linux2/blockdev.c,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -d -r1.40 -r1.41
--- blockdev.c 26 Mar 2006 20:46:54 -0000 1.40
+++ blockdev.c 9 May 2006 20:13:42 -0000 1.41
@@ -205,6 +205,14 @@
while ((mnte = getmntent_r (f, &mnt, buf, sizeof(buf))) != NULL) {
struct stat statbuf;
+ /* If this is a nfs mount (fstype == 'nfs') ignore the mount. Reason:
+ * 1. we don't list nfs devices in HAL
+ * 2. more problematic: stat on mountpoints with 'stale nfs handle' never come
+ * back and block complete HAL and all applications using HAL fail.
+ */
+ if (strcmp(mnt.mnt_type, "nfs") == 0)
+ continue;
+
/* check the underlying device of the mount point */
if (stat (mnt.mnt_dir, &statbuf) != 0)
continue;
More information about the hal-commit
mailing list