check daemon() return value
This commit is contained in:
parent
6890a27a3a
commit
3971c1f47c
@ -621,8 +621,8 @@ main(int argc, char *argv[])
|
|||||||
if (dflag && oflag) {
|
if (dflag && oflag) {
|
||||||
usage();
|
usage();
|
||||||
}
|
}
|
||||||
if (dflag) {
|
if (dflag && daemon(1, 1) < 0) {
|
||||||
(void)daemon(1, 1);
|
err(1, "daemon");
|
||||||
}
|
}
|
||||||
|
|
||||||
memset(&act, 0, sizeof(act));
|
memset(&act, 0, sizeof(act));
|
||||||
|
Loading…
Reference in New Issue
Block a user