aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAaro Koskinen <aaro.koskinen@iki.fi>2013-02-25 00:45:07 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2013-03-18 18:45:13 +0100
commit95e99e5271cb15247ba8926f0352387643164528 (patch)
tree46e73002c8639a4e11f548da7b5838b1f9f7267f
parent14285d14a5826eb172e02cf2f6f1ec096add01b0 (diff)
downloadbusybox-w32-95e99e5271cb15247ba8926f0352387643164528.tar.gz
busybox-w32-95e99e5271cb15247ba8926f0352387643164528.tar.bz2
busybox-w32-95e99e5271cb15247ba8926f0352387643164528.zip
sendmail: don't mangle e-mail headers
Leave the original To: and Cc: headers untouched, when we try to extract addresses from them. Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-rw-r--r--mailutils/sendmail.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/mailutils/sendmail.c b/mailutils/sendmail.c
index 4f73512e9..0f536adae 100644
--- a/mailutils/sendmail.c
+++ b/mailutils/sendmail.c
@@ -299,7 +299,9 @@ int sendmail_main(int argc UNUSED_PARAM, char **argv)
299 // To: or Cc: headers add recipients 299 // To: or Cc: headers add recipients
300 if (opts & OPT_t) { 300 if (opts & OPT_t) {
301 if (0 == strncasecmp("To:", s, 3) || 0 == strncasecmp("Bcc:" + 1, s, 3)) { 301 if (0 == strncasecmp("To:", s, 3) || 0 == strncasecmp("Bcc:" + 1, s, 3)) {
302 rcptto(sane_address(s+3)); 302 char *r = xstrdup(s+3);
303 rcptto(sane_address(r));
304 free(r);
303 goto addheader; 305 goto addheader;
304 } 306 }
305 // Bcc: header adds blind copy (hidden) recipient 307 // Bcc: header adds blind copy (hidden) recipient