cvs commit: qpsmtpd/lib/Qpsmtpd Constants.pm SMTP.pm

[email protected] (Robert Spier)
Newsgroups perl.cvs.qpsmtpd
Message-ID <[email protected]>
cvsuser     04/06/14 15:25:52

  Modified:    lib/Qpsmtpd Constants.pm SMTP.pm
  Log:
  DENY_DISCONNECT and DENYSOFT_DISCONNECT instead of *HARD
  
  Revision  Changes    Path
  1.10      +6 -3      qpsmtpd/lib/Qpsmtpd/Constants.pm
  
  Index: Constants.pm
  ===================================================================
  RCS file: /cvs/public/qpsmtpd/lib/Qpsmtpd/Constants.pm,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -w -r1.9 -r1.10
  --- Constants.pm	11 Jun 2004 06:12:16 -0000	1.9
  +++ Constants.pm	14 Jun 2004 22:25:52 -0000	1.10
  @@ -2,7 +2,9 @@
   use strict;
   require Exporter;
   
  -my (@common) = qw(OK DECLINED DONE DENY DENYSOFT DENYHARD DENYSOFTHARD);
  +my (@common) = qw(OK DECLINED DONE DENY DENYSOFT DENYHARD
  +                  DENY_DISCONNECT DENYSOFT_DISCONNECT
  +                 );
   my (@loglevels) = qw(LOGDEBUG LOGINFO LOGNOTICE LOGWARN LOGERROR LOGCRIT LOGALERT LOGEMERG LOGRADAR);
   
   use vars qw($VERSION @ISA @EXPORT);
  @@ -12,8 +14,9 @@
   use constant OK       => 900;
   use constant DENY     => 901;   # 550
   use constant DENYSOFT => 902;   # 450
  -use constant DENYHARD => 903;   # 550 + disconnect
  -use constant DENYSOFTHARD => 904; # 450 + disconnect
  +use constant DENYHARD => 903;   # 550 + disconnect  (deprecated in 0.29)
  +use constant DENY_DISCONNECT     => 903; # 550 + disconnect
  +use constant DENYSOFT_DISCONNECT => 904; # 450 + disconnect
   use constant DECLINED => 909;
   use constant DONE     => 910;
   
  
  
  
  1.28      +4 -4      qpsmtpd/lib/Qpsmtpd/SMTP.pm
  
  Index: SMTP.pm
  ===================================================================
  RCS file: /cvs/public/qpsmtpd/lib/Qpsmtpd/SMTP.pm,v
  retrieving revision 1.27
  retrieving revision 1.28
  diff -u -w -r1.27 -r1.28
  --- SMTP.pm	11 Jun 2004 06:11:27 -0000	1.27
  +++ SMTP.pm	14 Jun 2004 22:25:52 -0000	1.28
  @@ -230,13 +230,13 @@
         $self->log(LOGINFO, "denysoft mail from " . $from->format . " ($msg)");
         $self->respond(450, $msg);
       }
  -    elsif ($rc == DENYHARD) {
  +    elsif ($rc == DENY_DISCONNECT) {
         $msg ||= $from->format . ', denied';
         $self->log(LOGINFO, "deny mail from " . $from->format . " ($msg)");
         $self->respond(550, $msg);
         $self->disconnect;
       }
  -    elsif ($rc == DENYSOFTHARD) {
  +    elsif ($rc == DENYSOFT_DISCONNECT) {
         $msg ||= $from->format . ', temporarily denied';
         $self->log(LOGINFO, "denysoft mail from " . $from->format . " ($msg)");
         $self->respond(450, $msg);
  @@ -273,13 +273,13 @@
       $msg ||= 'relaying denied';
       return $self->respond(450, $msg);
     }
  -  elsif ($rc == DENYHARD) {
  +  elsif ($rc == DENY_DISCONNECT) {
         $msg ||= 'delivery denied';
         $self->log(LOGINFO, "delivery denied ($msg)");
         $self->respond(550, $msg);
         $self->disconnect;
     }
  -  elsif ($rc == DENYSOFTHARD) {
  +  elsif ($rc == DENYSOFT_DISCONNECT) {
       $msg ||= 'relaying denied';
       $self->log(LOGINFO, "delivery denied ($msg)");
       $self->respond(450, $msg);
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.