summaryrefslogtreecommitdiffstats
path: root/src/udev/collect
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2014-02-13 14:59:56 +0100
committerLennart Poettering <lennart@poettering.net>2014-02-13 14:59:56 +0100
commitc8a202b7d47f9d6bba3100a208abdadfc383499e (patch)
treed19560cf0723f8e2305170881eb442b5ecb12b0d /src/udev/collect
parenteverywhere: make use of new0() and macro() macros, and stop using perror() (diff)
downloadsystemd-c8a202b7d47f9d6bba3100a208abdadfc383499e.tar.xz
systemd-c8a202b7d47f9d6bba3100a208abdadfc383499e.zip
everywhere: always use O_CLOEXEC where it makes sense
Diffstat (limited to 'src/udev/collect')
-rw-r--r--src/udev/collect/collect.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/udev/collect/collect.c b/src/udev/collect/collect.c
index cb5df01c6a..4ecb6b0d19 100644
--- a/src/udev/collect/collect.c
+++ b/src/udev/collect/collect.c
@@ -95,7 +95,7 @@ static int prepare(char *dir, char *filename)
snprintf(buf, sizeof(buf), "%s/%s", dir, filename);
- fd = open(buf,O_RDWR|O_CREAT, S_IRUSR|S_IWUSR);
+ fd = open(buf,O_RDWR|O_CREAT|O_CLOEXEC, S_IRUSR|S_IWUSR);
if (fd < 0)
fprintf(stderr, "Cannot open %s: %m\n", buf);