X-Git-Url: http://git.tuebingen.mpg.de/?p=dss.git;a=blobdiff_plain;f=daemon.c;h=24bbfe5cdaaa22b03924fd4aba0cf379a1de22e1;hp=fe51fe03a5c614ba4cc8f34a0f29e1b79cd2cf8d;hb=fafaa26953e4f452c6b91de4e24ec5ad2a8f6700;hpb=66cdd5bc99a53d2b408a6cdc2d501fe27f9db13b diff --git a/daemon.c b/daemon.c index fe51fe0..24bbfe5 100644 --- a/daemon.c +++ b/daemon.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 1997-2010 Andre Noll + * Copyright (C) 1997-2010 Andre Noll * * Licensed under the GPL v2. For licencing details see COPYING. */ @@ -19,9 +19,9 @@ #include #include "gcc-compat.h" -#include "error.h" +#include "err.h" #include "log.h" -#include "string.h" +#include "str.h" #include "daemon.h" /** @@ -48,7 +48,7 @@ void daemon_init(void) if (chdir("/") < 0) goto err; umask(0); - null = open("/dev/null", O_RDONLY); + null = open("/dev/null", O_RDWR); if (null < 0) goto err; if (dup2(null, STDIN_FILENO) < 0)