diff options
Diffstat (limited to 'src/random-seed/random-seed.c')
-rw-r--r-- | src/random-seed/random-seed.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/random-seed/random-seed.c b/src/random-seed/random-seed.c index 71c2dba431..510a2715f2 100644 --- a/src/random-seed/random-seed.c +++ b/src/random-seed/random-seed.c @@ -10,6 +10,7 @@ #include "alloc-util.h" #include "fd-util.h" +#include "fs-util.h" #include "io-util.h" #include "log.h" #include "main-func.h" @@ -156,8 +157,7 @@ static int run(int argc, char *argv[]) { /* This is just a safety measure. Given that we are root and * most likely created the file ourselves the mode and owner * should be correct anyway. */ - (void) fchmod(seed_fd, 0600); - (void) fchown(seed_fd, 0, 0); + (void) fchmod_and_chown(seed_fd, 0600, 0, 0); k = loop_read(random_fd, buf, buf_size, false); if (k < 0) |