aboutsummaryrefslogtreecommitdiffstats
path: root/perl
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@rambler-co.ru>2009-12-14 20:02:14 +0300
committerVsevolod Stakhov <vsevolod@rambler-co.ru>2009-12-14 20:02:14 +0300
commit1cf238549b8a2626f537f00b215e75eb19621570 (patch)
tree4391ccc6863654364eadf3048815f3edee4cc243 /perl
parent9f300615e8fca8076266de1a220c74a226d09979 (diff)
downloadrspamd-1cf238549b8a2626f537f00b215e75eb19621570.tar.gz
rspamd-1cf238549b8a2626f537f00b215e75eb19621570.zip
* Fix issue with list concat
Diffstat (limited to 'perl')
-rw-r--r--perl/lib/Mail/Rspamd/Client.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/perl/lib/Mail/Rspamd/Client.pm b/perl/lib/Mail/Rspamd/Client.pm
index 32801b9ab..1fcaef130 100644
--- a/perl/lib/Mail/Rspamd/Client.pm
+++ b/perl/lib/Mail/Rspamd/Client.pm
@@ -168,7 +168,7 @@ sub check {
$self->{resp_code} = $resp_code;
$self->{resp_msg} = $resp_msg;
- return undef unless ($resp_code == 0);
+ return undef unless (defined($resp_code) && $resp_code == 0);
my $cur_metric;
my @lines = split (/^/, $in);
@@ -297,7 +297,7 @@ sub ping {
return undef unless $line;
my ($version, $resp_code, $resp_msg) = $self->_parse_response_line($line);
- return 0 unless ($resp_msg eq 'PONG');
+ return 0 unless (defined($resp_msg) && $resp_msg eq 'PONG');
return 1;
}