summaryrefslogtreecommitdiff
path: root/src/udev/udev-event.c
diff options
context:
space:
mode:
authorAnthony G. Basile <blueness@gentoo.org>2013-03-31 22:00:59 -0400
committerIan Stakenvicius <axs@gentoo.org>2013-04-02 15:02:48 -0400
commit601c4e8ce69338652b3c9178386cbc05de8bae8d (patch)
tree8c76835f8bc34a1dd81e1f48ec38c02b32e3e766 /src/udev/udev-event.c
parent20d47ae5b565723c596b5c8afbfd6f7583a9f49e (diff)
udev: update
This updates the daemon codebase to upstream. Authors: Zbigniew Jędrzejewski-Szmek Lennart Poettering Václav Pavlín Kay Sievers Harald Hoyer Rob Clark Zeeshan Ali (Khattak) See http://cgit.freedesktop.org/systemd/systemd/log/src/udev Ian is signing off but has some concerns on a few of the changes that he may fix in future commits. Signed-off-by: Anthony G. Basile <blueness@gentoo.org> Signed-off-by: Ian Stakenvicius <axs@gentoo.org>
Diffstat (limited to 'src/udev/udev-event.c')
-rw-r--r--src/udev/udev-event.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/udev/udev-event.c b/src/udev/udev-event.c
index 01b503ef1c..d1880efe50 100644
--- a/src/udev/udev-event.c
+++ b/src/udev/udev-event.c
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2003-2010 Kay Sievers <kay@vrfy.org>
+ * Copyright (C) 2003-2013 Kay Sievers <kay@vrfy.org>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -845,6 +845,8 @@ int udev_event_execute_rules(struct udev_event *event, struct udev_rules *rules,
}
if (major(udev_device_get_devnum(dev)) > 0) {
+ bool apply;
+
/* remove/update possible left-over symlinks from old database entry */
if (event->dev_db != NULL)
udev_node_update_old_links(dev, event->dev_db);
@@ -868,7 +870,8 @@ int udev_event_execute_rules(struct udev_event *event, struct udev_rules *rules,
}
}
- udev_node_add(dev, event->mode, event->uid, event->gid);
+ apply = streq(udev_device_get_action(dev), "add") || event->owner_set || event->group_set || event->mode_set;
+ udev_node_add(dev, apply, event->mode, event->uid, event->gid);
}
/* preserve old, or get new initialization timestamp */