Fix minor descriptor leak, found by Coverity Scan
It is safe to always close() the fd here. Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
parent
f06ab73e13
commit
39ea566d45
@ -2036,7 +2036,6 @@ static int waitdaemon(int maxwait)
|
||||
(void)dup2(fd, STDIN_FILENO);
|
||||
(void)dup2(fd, STDOUT_FILENO);
|
||||
(void)dup2(fd, STDERR_FILENO);
|
||||
if (fd > STDERR_FILENO)
|
||||
(void)close(fd);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user