summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xutils/redirector.pl.in5
1 files changed, 4 insertions, 1 deletions
diff --git a/utils/redirector.pl.in b/utils/redirector.pl.in
index 9dd6a24f0..3ed8838e2 100755
--- a/utils/redirector.pl.in
+++ b/utils/redirector.pl.in
@@ -439,7 +439,10 @@ while (my $arg = shift @ARGV) {
die "Process is already started, check $cfg{pidfile}" if Proc::PidUtil::is_running($cfg{pidfile});
# Do daemonization
-Proc::Daemon::Init if !$cfg{debug};
+if (!$cfg{debug}) {
+ Proc::Daemon::Init;
+ POE::Kernel->has_forked;
+}
# Drop privilleges
if ($> == 0) {