Fix tsyslogd, which reads from stdin, exit on EOF
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
parent
56ff4eedbe
commit
a8060d0ad1
@ -1227,11 +1227,12 @@ int main(int argc, char *argv[])
|
|||||||
if (i > 0) {
|
if (i > 0) {
|
||||||
printchopped(LocalHostName, line, i + 1, fileno(stdin));
|
printchopped(LocalHostName, line, i + 1, fileno(stdin));
|
||||||
} else if (i < 0) {
|
} else if (i < 0) {
|
||||||
if (errno != EINTR) {
|
if (errno != EINTR)
|
||||||
logerror("stdin");
|
logerror("stdin");
|
||||||
}
|
} else {
|
||||||
}
|
logit("EOF\n");
|
||||||
FD_CLR(fileno(stdin), &readfds);
|
exit(0);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user