chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
udevd: rules files - accept empty or /dev/null links
[elogind.git]
/
libudev
/
libudev-device-private.c
diff --git
a/libudev/libudev-device-private.c
b/libudev/libudev-device-private.c
index 6d72d328bd88eab4ffe4355b4607a861e3954ae9..ee9e297cea2ef21770841f16ec932587c1917eef 100644
(file)
--- a/
libudev/libudev-device-private.c
+++ b/
libudev/libudev-device-private.c
@@
-134,6
+134,13
@@
int udev_device_update_db(struct udev_device *udev_device)
return -1;
}
return -1;
}
+ /*
+ * set 'sticky' bit to indicate that we should not clean the
+ * database when we transition from initramfs to the real root
+ */
+ if (udev_device_get_db_persist(udev_device))
+ fchmod(fileno(f), 01644);
+
if (has_info) {
size_t devlen = strlen(udev_get_dev_path(udev))+1;
struct udev_list_entry *list_entry;
if (has_info) {
size_t devlen = strlen(udev_get_dev_path(udev))+1;
struct udev_list_entry *list_entry;