diff options
Diffstat (limited to 'usr.sbin/smtpd')
-rw-r--r-- | usr.sbin/smtpd/enqueue.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/usr.sbin/smtpd/enqueue.c b/usr.sbin/smtpd/enqueue.c index b0797e918b3..d00e99b2874 100644 --- a/usr.sbin/smtpd/enqueue.c +++ b/usr.sbin/smtpd/enqueue.c @@ -1,4 +1,4 @@ -/* $OpenBSD: enqueue.c,v 1.78 2014/04/04 16:10:42 eric Exp $ */ +/* $OpenBSD: enqueue.c,v 1.79 2014/04/04 20:25:44 gilles Exp $ */ /* * Copyright (c) 2005 Henning Brauer <henning@bulabula.org> @@ -187,12 +187,16 @@ send_header(FILE *fout, const char *line, size_t len) pstate.wpos = len - 1; msg.rcpts = NULL; msg.rcpt_cnt = 0; - if (strncasecmp("From:", line, 5) == 0) + + if (strncasecmp("From:", line, 5) == 0) { parse_addr_terminal(1); - else + send_line(fout, 0, "%s\n", msg.from); + } + else { parse_addr_terminal(0); - for (i = 0; i < msg.rcpt_cnt; ++i) - send_line(fout, 0, "%s%s\n", msg.rcpts[i], i < msg.rcpt_cnt - 1 ? "," : ""); + for (i = 0; i < msg.rcpt_cnt; ++i) + send_line(fout, 0, "%s%s\n", msg.rcpts[i], i < msg.rcpt_cnt - 1 ? "," : ""); + } } int |