[otrs-cvs] CVS: otrs/Kernel/System/Log File.pm,1.9,1.10
cvs-log at otrs.org
cvs-log at otrs.org
Thu Nov 2 13:20:57 CET 2006
Update of /home/cvs/otrs/Kernel/System/Log
In directory lancelot:/tmp/cvs-serv11671/Kernel/System/Log
Modified Files:
File.pm
Log Message:
removed # --
Index: File.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/System/Log/File.pm,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -r1.9 -r1.10
*** File.pm 29 Aug 2006 17:28:44 -0000 1.9
--- File.pm 2 Nov 2006 12:20:55 -0000 1.10
***************
*** 20,24 ****
umask 002;
- # --
sub new {
my $Type = shift;
--- 20,23 ----
***************
*** 42,52 ****
return $Self;
}
! # --
sub Log {
my $Self = shift;
my %Param = @_;
! # --
# open logfile
- # --
if (open (LOGFILE, ">> $Self->{LogFile}")) {
print LOGFILE "[".localtime()."]";
--- 41,50 ----
return $Self;
}
!
sub Log {
my $Self = shift;
my %Param = @_;
!
# open logfile
if (open (LOGFILE, ">> $Self->{LogFile}")) {
print LOGFILE "[".localtime()."]";
***************
*** 61,67 ****
}
elsif ($Param{Priority} =~ /error/i) {
- # --
# print error messages to LOGFILE
- # --
print LOGFILE "[Error][$Param{Module}][$Param{Line}] $Param{Message}\n";
}
--- 59,63 ----
***************
*** 72,85 ****
print LOGFILE "[Error][$Param{Module}] Priority: '$Param{Priority}' not defined! Message: $Param{Message}\n";
}
! # --
# close file handle
- # --
close (LOGFILE);
return 1;
}
else {
- # --
# print error screen
- # --
print STDERR "\n";
print STDERR " >> Can't write $Self->{LogFile}: $! <<\n";
--- 68,78 ----
print LOGFILE "[Error][$Param{Module}] Priority: '$Param{Priority}' not defined! Message: $Param{Message}\n";
}
!
# close file handle
close (LOGFILE);
return 1;
}
else {
# print error screen
print STDERR "\n";
print STDERR " >> Can't write $Self->{LogFile}: $! <<\n";
***************
*** 88,91 ****
}
}
! # --
1;
--- 81,84 ----
}
}
!
1;
More information about the cvs-log
mailing list