1 #ifndef CCAN_DAEMONIZE_H
2 #define CCAN_DAEMONIZE_H
6 * daemonize - turn this process into a daemon.
8 * This routine forks us off to become a daemon. It returns false on failure
9 * (ie. fork() failed) and sets errno.
11 * Side effects for programmers to be aware of:
12 * - PID changes (our parent exits, we become child of init)
13 * - stdin, stdout and stderr file descriptors are closed
14 * - Current working directory changes to /
15 * - Umask is set to 0.
19 #endif /* CCAN_DAEMONIZE_H */