From ce781bdbf068035691e842cd00e559f261771fd9 Mon Sep 17 00:00:00 2001 From: Andrew Ruthven Date: Sun, 23 Dec 2007 22:07:16 +1300 Subject: [PATCH] Get rid of an extra newline that sometimes sneaks into the log messages. --- src/lib/Spong/Logger.pm | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/lib/Spong/Logger.pm b/src/lib/Spong/Logger.pm index 3e7f9e3..627cf18 100755 --- a/src/lib/Spong/Logger.pm +++ b/src/lib/Spong/Logger.pm @@ -73,6 +73,9 @@ sub log { my( $self, $message, $pri ) = @_; $pri = $self->{priority} if ! defined $pri; + # Remove any extraneous newlines. + chomp($message); + if ($self->{stdout}) { print scalar localtime() , " ", $message,"\n"; } if ($self->{stderr}) { print STDERR scalar localtime(), " ",$message,"\n"; } -- 2.30.2