Fixed loggin.
git-svn-id: http://svn.zoneminder.com/svn/zm/trunk@219 e3e1d417-86f3-4887-817a-d78f3d33393fpull/27/merge
parent
3e29ec48e3
commit
c8fc6dc37d
|
@ -39,7 +39,7 @@ use constant DB_NAME => "zm";
|
|||
use constant DB_USER => "zmadmin";
|
||||
use constant DB_PASS => "zmadminzm";
|
||||
use constant EVENT_PATH => "/data/zm/events";
|
||||
use constant AUDIT_LOG_FILE => '/tmp/zmaudit.log';
|
||||
use constant LOG_FILE => '/tmp/zmaudit.log';
|
||||
|
||||
# ==========================================================================
|
||||
#
|
||||
|
@ -129,9 +129,9 @@ if ( !$yes && !$report )
|
|||
{
|
||||
ReadMode( 'cbreak' );
|
||||
}
|
||||
if ( !$delay ) # Background mode
|
||||
if ( $delay ) # Background mode
|
||||
{
|
||||
open( LOG, ">>".AUDIT_LOG_FILE ) or die( "Can't open log file: $!" );
|
||||
open( LOG, ">>".LOG_FILE ) or die( "Can't open log file: $!" );
|
||||
open( STDOUT, ">&LOG" ) || die( "Can't dup stdout: $!" );
|
||||
select( STDOUT ); $| = 1;
|
||||
open( STDERR, ">&LOG" ) || die( "Can't dup stderr: $!" );
|
||||
|
|
Loading…
Reference in New Issue