On Sun, 3 Sep 2006, W. Tait Cyrus wrote:
Can someone verify if this is a bug.
In file:
lib/Qpsmtpd/SMTP.pm
in rcpt() in the elsif for $rc == DENY, I believe that there is a "return"
missing. The code is currently:
elsif ($rc == DENY) {
$msg ||= 'relaying denied';
$self->respond(550, $msg);
}
Perl implicitly returns the output of the last expression/value in a
method (there's probably a more concise definition in Programming Perl 3rd
edition, that's off the top of my head).
So this is not really a bug, it's just programming style.
and I believe it should be:
elsif ($rc == DENY) {
$msg ||= 'relaying denied';
return $self->respond(550, $msg);
}
All other cases in the rcpt() routine "return" the value from $self->respond
++Tait