diff options
author | Tom Gundersen <teg@jklm.no> | 2015-03-06 18:30:09 +0100 |
---|---|---|
committer | Tom Gundersen <teg@jklm.no> | 2015-03-12 11:59:04 +0100 |
commit | 1cd0a77022a4da17d1274f8f776b63e72c99fb05 (patch) | |
tree | 35662cbbbf0f62cdf131e6e5a2f4e20eaa9bd239 /src/udev/udev-event.c | |
parent | boot: efi - add config option to disable the command line editor (diff) | |
download | systemd-1cd0a77022a4da17d1274f8f776b63e72c99fb05.tar.xz systemd-1cd0a77022a4da17d1274f8f776b63e72c99fb05.zip |
libudev: introduce udev_device_properties_copy()
To copy properties from one device to another. Drop the equivalent functionality from udevd.
Diffstat (limited to 'src/udev/udev-event.c')
-rw-r--r-- | src/udev/udev-event.c | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/src/udev/udev-event.c b/src/udev/udev-event.c index 67fb1f78f5..b96cf737f5 100644 --- a/src/udev/udev-event.c +++ b/src/udev/udev-event.c @@ -819,18 +819,8 @@ void udev_event_execute_rules(struct udev_event *event, } if (major(udev_device_get_devnum(dev)) == 0 && - streq(udev_device_get_action(dev), "move")) { - struct udev_list_entry *entry; - - for ((entry = udev_device_get_properties_list_entry(event->dev_db)); entry; entry = udev_list_entry_get_next(entry)) { - const char *key, *value; - - key = udev_list_entry_get_name(entry); - value = udev_list_entry_get_value(entry); - - udev_device_add_property(dev, key, value); - } - } + streq(udev_device_get_action(dev), "move")) + udev_device_copy_properties(dev, event->dev_db); udev_rules_apply_to_event(rules, event, timeout_usec, timeout_warn_usec, |