From a3ef21b122a0fbfe234c6cfd37fd0d00d8156506 Mon Sep 17 00:00:00 2001 From: Jeremy Sowden Date: Mon, 27 May 2019 22:52:13 +0100 Subject: [PATCH] wmail: skip leading white-space in From: headers. --- wmail/src/wmail.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/wmail/src/wmail.c b/wmail/src/wmail.c index 2c06d9b..149bda6 100644 --- a/wmail/src/wmail.c +++ b/wmail/src/wmail.c @@ -34,6 +34,7 @@ /////////////////////////////////////////////////////////////////////////////// // includes +#include #include #include #include @@ -936,7 +937,8 @@ char *ParseFromField( char *buf ) continue; } // else do the default action default: - fullName[ strlen( fullName ) ] = *c; + if( fullName[0] != '\0' || !isspace ( *c )) + fullName[ strlen( fullName ) ] = *c; } continue;