#endif /* WITH_CONTENT_SCAN */
#ifdef EXPERIMENTAL_PRDR
- if (prdr_requested && recipients_count > 0 && acl_smtp_data_prdr != NULL )
+ if (prdr_requested && recipients_count > 1 && acl_smtp_data_prdr != NULL )
{
unsigned int c;
int all_pass = OK;
else if (user_msg) log_write(0, LOG_MAIN, "PRDR %s %s", addr, user_msg);
else log_write(0, LOG_MAIN, msg);
- if (rc != OK)
- receive_remove_recipient(recipients_list[c--].address);
+ if (rc != OK) { receive_remove_recipient(addr); c--; }
}
/* Set up final message, used if data acl gives OK */
smtp_reply = string_sprintf("%s id=%s message %s",
? US"accepted"
: US"accepted for some recipients");
}
+ else
+ prdr_requested = FALSE;
#endif /* EXPERIMENTAL_PRDR */
/* Check the recipients count again, as the MIME ACL might have changed
1999-03-02 09:44:33 10HmaX-0005vi-00 PRDR R=<userp@test.ex> acceptance
1999-03-02 09:44:33 10HmaX-0005vi-00 PRDR R=<userq@test.ex> acceptance
1999-03-02 09:44:33 10HmaX-0005vi-00 H=(rhu.barb) [127.0.0.1] F=<> rejected after DATA
+1999-03-02 09:44:33 10HmaZ-0005vi-00 <= <> H=(rhu.barb) [127.0.0.1] P=esmtp S=sss
+1999-03-02 09:44:33 10HmaZ-0005vi-00 => user1 <user1@test.ex> R=r0 T=t1
+1999-03-02 09:44:33 10HmaZ-0005vi-00 Completed
--- /dev/null
+From MAILER-DAEMON Tue Mar 02 09:44:33 1999
+Received: from [127.0.0.1] (helo=rhu.barb)
+ by myhost.test.ex with esmtp (Exim x.yz)
+ id 10HmaZ-0005vi-00
+ for user1@test.ex; Tue, 2 Mar 1999 09:44:33 +0000
+Sender: sender@some.where
+
+
??? 221
****
sleep 1
+#
+#
+# 3: PRDR should be avoided for a single-recipient message
+# even though the client showed support.
+client 127.0.0.1 PORT_D
+??? 220
+ehlo rhu.barb
+??? 250-
+??? 250-
+??? 250-
+??? 250-
+??? 250-PRDR
+??? 250
+mail from:<> PRDR
+??? 250
+rcpt to:<user1@test.ex>
+??? 250
+data
+??? 354
+Sender: sender@some.where
+.
+??? 250
+quit
+??? 221
+****
+sleep 1
+#
killdaemon
#
??? 221
<<< 221 myhost.test.ex closing connection
End of script
+Connecting to 127.0.0.1 port 1225 ... connected
+??? 220
+<<< 220 myhost.test.ex ESMTP Exim x.yz Tue, 2 Mar 1999 09:44:33 +0000
+>>> ehlo rhu.barb
+??? 250-
+<<< 250-myhost.test.ex Hello rhu.barb [127.0.0.1]
+??? 250-
+<<< 250-SIZE 52428800
+??? 250-
+<<< 250-8BITMIME
+??? 250-
+<<< 250-PIPELINING
+??? 250-PRDR
+<<< 250-PRDR
+??? 250
+<<< 250 HELP
+>>> mail from:<> PRDR
+??? 250
+<<< 250 OK, PRDR Requested
+>>> rcpt to:<user1@test.ex>
+??? 250
+<<< 250 Accepted
+>>> data
+??? 354
+<<< 354 Enter message, ending with "." on a line by itself
+>>> Sender: sender@some.where
+>>> .
+??? 250
+<<< 250 OK id=10HmaZ-0005vi-00
+>>> quit
+??? 221
+<<< 221 myhost.test.ex closing connection
+End of script