diff options
Diffstat (limited to 'runit')
-rw-r--r-- | runit/svlogd.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/runit/svlogd.c b/runit/svlogd.c index 9a00fad..fe40cd8 100644 --- a/runit/svlogd.c +++ b/runit/svlogd.c @@ -761,8 +761,8 @@ static NOINLINE unsigned logdir_open(struct logdir *ld, const char *fn) } while ((ld->fdcur = open("current", O_WRONLY|O_NDELAY|O_APPEND|O_CREAT, 0600)) == -1) pause2cannot("open current", ld->name); - /* we presume this cannot fail */ - ld->filecur = fdopen(ld->fdcur, "a"); //// + while ((ld->filecur = fdopen(ld->fdcur, "a")) == NULL) + pause2cannot("open current", ld->name); //// setvbuf(ld->filecur, NULL, _IOFBF, linelen); //// close_on_exec_on(ld->fdcur); |