diff --git a/plugins/spamassassin b/plugins/spamassassin index 5b62153..5ca7e76 100644 --- a/plugins/spamassassin +++ b/plugins/spamassassin @@ -102,7 +102,8 @@ sub hook_data_post { # check_spam my $remote = 'localhost'; my $port = 783; - if ($self->{_args}->{spamd_socket} =~ /^([\w.-]+):(\d+)$/) { + if (defined $self->{_args}->{spamd_socket} + && $self->{_args}->{spamd_socket} =~ /^([\w.-]+):(\d+)$/) { $remote = $1; $port = $2; }