summaryrefslogtreecommitdiff
path: root/src/udev/udevadm-trigger.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/udev/udevadm-trigger.c')
-rw-r--r--src/udev/udevadm-trigger.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/udev/udevadm-trigger.c b/src/udev/udevadm-trigger.c
index 087ee4bfae..0ee27bb408 100644
--- a/src/udev/udevadm-trigger.c
+++ b/src/udev/udevadm-trigger.c
@@ -51,7 +51,7 @@ static void exec_list(struct udev_enumerate *udev_enumerate, const char *action)
if (dry_run)
continue;
strscpyl(filename, sizeof(filename), udev_list_entry_get_name(entry), "/uevent", NULL);
- fd = open(filename, O_WRONLY);
+ fd = open(filename, O_WRONLY|O_CLOEXEC);
if (fd < 0)
continue;
if (write(fd, action, strlen(action)) < 0)