summaryrefslogtreecommitdiff
path: root/udev.c
diff options
context:
space:
mode:
Diffstat (limited to 'udev.c')
-rw-r--r--udev.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/udev.c b/udev.c
index 6d1d679d9a..23375b7a3e 100644
--- a/udev.c
+++ b/udev.c
@@ -141,7 +141,7 @@ int main(int argc, char *argv[], char *envp[])
if (!subsystem && argc == 2)
subsystem = argv[1];
- udev_init_device(&udev, devpath, subsystem);
+ udev_init_device(&udev, devpath, subsystem, action);
if (!action || !subsystem || !devpath) {
err("action, subsystem or devpath missing");
@@ -230,10 +230,11 @@ int main(int argc, char *argv[], char *envp[])
}
hotplug:
- udev_cleanup_device(&udev);
if (udev_hotplug_d && managed_event)
udev_multiplex_directory(&udev, HOTPLUGD_DIR, HOTPLUG_SUFFIX);
+ udev_cleanup_device(&udev);
+
logging_close();
return retval;
}