--- lmtp2nntp.c 2001/08/23 08:30:41 1.25
+++ lmtp2nntp.c 2001/08/23 08:36:53 1.26
@@ -402,8 +402,8 @@
* RFC1893 2. Status Codes 5.X.X Permanent Failure
* RFC1893 3.5 Network and Routing Status X.0.0 Other undefined Status
*/
- if (! ( helo_rfc0821domain(req->msg, &ctx->session.lhlo_domain)
- || helo_rfc1035domain(req->msg, &ctx->session.lhlo_domain))) {
+ if (! ( helo_rfc0821domain(req->msg, &ctx->session.lhlo_domain) > 0
+ || helo_rfc1035domain(req->msg, &ctx->session.lhlo_domain) > 0)) {
res.statuscode = "501";
res.dsncode = "5.0.0";
res.statusmsg = "Please identify yourself. Domain must match RFC0821/RFC1035.";
@@ -674,7 +674,7 @@
* RFC1893 2. Status Codes 5.X.X Permanent Failure
* RFC1893 3.5 Network and Routing Status X.1.7 Bad sender's mailbox address syntax
*/
- if (!str_parse(req->msg, "m/^MAIL From:\\s*<(?:.+@.+)>/i")) {
+ if (str_parse(req->msg, "m/^MAIL From:\\s*<(?:.+@.+)>/i") <= 0) {
res.statuscode = "553";
res.dsncode = "5.1.7";
res.statusmsg = "Domain name required for sender address.";
@@ -687,9 +687,9 @@
* RFC1893 2. Status Codes 5.X.X Permanent Failure
* RFC1893 3.5 Network and Routing Status X.5.4 Invalid command arguments
*/
- if (!str_parse(req->msg, "m/^MAIL From:\\s*<(.+@.+)>"
- "(?:\\s+BODY=(?:7BIT|8BITMIME)\\s*)?$/i",
- &ctx->msg->mail_from)) {
+ if (str_parse(req->msg, "m/^MAIL From:\\s*<(.+@.+)>"
+ "(?:\\s+BODY=(?:7BIT|8BITMIME)\\s*)?$/i",
+ &ctx->msg->mail_from) <= 0) {
res.statuscode = "501";
res.dsncode = "5.5.4";
res.statusmsg = "Unknown parameter for keyword BODY.";
@@ -733,7 +733,7 @@
* RFC1893 2. Status Codes 5.X.X Permanent Failure
* RFC1893 3.5 Network and Routing Status X.5.2 Syntax error
*/
- if (!str_parse(req->msg, "m/^RCPT To:\\s*(.+)$/i", &cp)) {
+ if (str_parse(req->msg, "m/^RCPT To:\\s*(.+)$/i", &cp) <= 0) {
res.statuscode = "501";
res.dsncode = "5.5.2";
res.statusmsg = "Syntax error in parameters.";
@@ -764,7 +764,7 @@
* X.7.2 Mailing list expansion prohibited
*/
if (ctx->option_groupmode == GROUPMODE_ENVELOPE) {
- if (!str_parse(cp, "m/^<(.+)?@[^@]+>$/i", &group)) {
+ if (str_parse(cp, "m/^<(.+)?@[^@]+>$/i", &group) <= 0) {
res.statuscode = "550";
res.dsncode = "5.1.1";
res.statusmsg = "Recipient did not transform into group.";
|