Fixed issue with unpriveliged user failing to open debug log.

git-svn-id: http://svn.zoneminder.com/svn/zm/trunk@1781 e3e1d417-86f3-4887-817a-d78f3d33393f
pull/27/merge
stan 2006-01-12 00:21:04 +00:00
parent 5992087d72
commit f018eb2246
1 changed files with 4 additions and 1 deletions

View File

@ -60,7 +60,10 @@ $ENV{PATH} = '/bin:/usr/bin';
$ENV{SHELL} = '/bin/sh' if exists $ENV{SHELL};
delete @ENV{qw(IFS CDPATH ENV BASH_ENV)};
zmDbgInit( DBG_ID, level=>DBG_LEVEL );
my $web_uid = (getpwnam( ZM_WEB_USER ))[2];
my $use_log = (($> == 0) || ($> == $web_uid));
zmDbgInit( DBG_ID, level=>DBG_LEVEL, to_log=>$use_log );
my $check = 0;
my $freshen = 0;