From: janw Date: Tue, 15 Jan 2008 09:33:59 +0000 (+0000) Subject: Should not map STD* if foreground. X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=4531e1ac2fc6b9b575751be6caad5fc8876850dd;p=gosa.git Should not map STD* if foreground. git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@8343 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-si/gosa-si-client b/gosa-si/gosa-si-client index 2608e323e..544030cdb 100755 --- a/gosa-si/gosa-si-client +++ b/gosa-si/gosa-si-client @@ -1254,9 +1254,11 @@ GetOptions("h|help" => \&usage, &read_configfile; &check_pid; -open STDIN, '/dev/null' or die "Can’t read /dev/null: $!"; -open STDOUT, '>>/dev/null' or die "Can't write to /dev/null: $!"; -open STDERR, '>>/dev/null' or die "Can't write to /dev/null: $!"; +if ( ! $foreground ) { + open STDIN, '/dev/null' or die "Can’t read /dev/null: $!"; + open STDOUT, '>>/dev/null' or die "Can't write to /dev/null: $!"; + open STDERR, '>>/dev/null' or die "Can't write to /dev/null: $!"; +} # restart daemon log file