$msg is an arrayref, dereference it before passing to $self->respond.
Before this, the SMTP responses contained the reference stringification instead of the real message, when a plugin denied the mail at the DATA stage: 554 ARRAY(0x9362f10) git-svn-id: https://svn.perl.org/qpsmtpd/trunk@881 958fd67b-6ff1-0310-b445-bb7760255be9
This commit is contained in:
parent
149c9c4790
commit
b2532e8daa
@ -183,22 +183,26 @@ sub data_respond {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
elsif ($rc == DENY) {
|
elsif ($rc == DENY) {
|
||||||
$self->respond(554, $msg || "Message denied");
|
$msg->[0] ||= "Message denied";
|
||||||
|
$self->respond(554, @$msg);
|
||||||
$self->reset_transaction();
|
$self->reset_transaction();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
elsif ($rc == DENYSOFT) {
|
elsif ($rc == DENYSOFT) {
|
||||||
$self->respond(451, $msg || "Message denied temporarily");
|
$msg->[0] ||= "Message denied temporarily";
|
||||||
|
$self->respond(451, @$msg);
|
||||||
$self->reset_transaction();
|
$self->reset_transaction();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
elsif ($rc == DENY_DISCONNECT) {
|
elsif ($rc == DENY_DISCONNECT) {
|
||||||
$self->respond(554, $msg || "Message denied");
|
$msg->[0] ||= "Message denied";
|
||||||
|
$self->respond(554, @$msg);
|
||||||
$self->disconnect;
|
$self->disconnect;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
elsif ($rc == DENYSOFT_DISCONNECT) {
|
elsif ($rc == DENYSOFT_DISCONNECT) {
|
||||||
$self->respond(451, $msg || "Message denied temporarily");
|
$msg->[0] ||= "Message denied temporarily";
|
||||||
|
$self->respond(451, @$msg);
|
||||||
$self->disconnect;
|
$self->disconnect;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user