summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndre Noll <maan@tuebingen.mpg.de>2016-06-14 10:40:22 +0200
committerAndre Noll <maan@tuebingen.mpg.de>2016-08-21 21:13:25 +0200
commit7da9a331fbbfb10a35fd9d014c47edbad13ffed7 (patch)
treea21b0a8c1959410c865036dd00e45208216db184
parent1c6346c95e20aaff69e27ecb6deacbd496000dca (diff)
daemon: Do not change to /.
This is pointless because we immediately cd back into the destination dir anyway.
-rw-r--r--daemon.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/daemon.c b/daemon.c
index 24bbfe5..86e8906 100644
--- a/daemon.c
+++ b/daemon.c
@@ -45,8 +45,6 @@ void daemon_init(void)
/* become session leader */
if (setsid() < 0)
goto err;
- if (chdir("/") < 0)
- goto err;
umask(0);
null = open("/dev/null", O_RDWR);
if (null < 0)