From: Eric Leblond Date: Fri, 5 Oct 2012 06:26:16 +0000 (+0200) Subject: suricata: change dir to / in daemon mode. X-Git-Tag: suricata-1.4beta3~25 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=24d10de8af0f27fa1013659d3f9af5fd45ed9259;p=thirdparty%2Fsuricata.git suricata: change dir to / in daemon mode. By changing directory to /, we will not block the directory where suricata has been started. --- diff --git a/src/util-daemon.c b/src/util-daemon.c index dad536b8ff..9215d3b73d 100644 --- a/src/util-daemon.c +++ b/src/util-daemon.c @@ -133,6 +133,8 @@ void Daemonize (void) { exit(EXIT_FAILURE); } */ + chdir("/"); + SetupLogging(); /* Child is ready, tell its parent */