limiting message size to prevent syslog warnings piling up
authorerickson <erickson@9efc2488-bf62-4759-914b-345cdb29e865>
Mon, 22 May 2006 18:23:15 +0000 (18:23 +0000)
committererickson <erickson@9efc2488-bf62-4759-914b-345cdb29e865>
Mon, 22 May 2006 18:23:15 +0000 (18:23 +0000)
git-svn-id: svn://svn.open-ils.org/OpenSRF/trunk@722 9efc2488-bf62-4759-914b-345cdb29e865

src/perlmods/OpenSRF/Utils/Logger.pm

index 53e2990..7db43a0 100644 (file)
@@ -208,6 +208,8 @@ sub _log_message {
 
        $msg = "[$n:"."$$".":::] $msg";
 
+       $msg = substr($msg, 0, 2000); 
+
        if( $level == ACTIVITY() ) {
                if( is_act_syslog() ) { syslog( $fac | $l, $msg ); } 
                elsif( is_act_filelog() ) { _write_file( $msg, 1 ); }