summaryrefslogtreecommitdiff
path: root/src/udev/udev-event.c
diff options
context:
space:
mode:
authorRobert Milasan <rmilasan@suse.com>2014-09-13 15:18:37 +0200
committerAnthony G. Basile <blueness@gentoo.org>2014-09-18 18:48:25 -0400
commita580624ac3f9c49e94b0ff97c6df459b87d6afac (patch)
tree749f69086ba99f91368020830e209422ea619123 /src/udev/udev-event.c
parentabc50f3d922a50905063c2cc0dd64dfd1b0b9e6c (diff)
udev: fix path for database names on 'change' event
If a device does not have a major/minor number attached, we use different database names than if it does. On "change" events, we didn't copy the devnum over, therefore, we used different paths than on 'add' or 'remove' events (where devnum was properly copied). Fix this by always copying the devnum into the udev-device. (David: added commit-log from email) Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
Diffstat (limited to 'src/udev/udev-event.c')
-rw-r--r--src/udev/udev-event.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/udev/udev-event.c b/src/udev/udev-event.c
index 068e4fb167..e86f9cb059 100644
--- a/src/udev/udev-event.c
+++ b/src/udev/udev-event.c
@@ -873,6 +873,7 @@ void udev_event_execute_rules(struct udev_event *event,
if (event->dev_db != NULL) {
udev_device_set_syspath(event->dev_db, udev_device_get_syspath(dev));
udev_device_set_subsystem(event->dev_db, udev_device_get_subsystem(dev));
+ udev_device_set_devnum(event->dev_db, udev_device_get_devnum(dev));
udev_device_read_db(event->dev_db, NULL);
udev_device_set_info_loaded(event->dev_db);