aboutsummaryrefslogtreecommitdiffstats
path: root/rfc822.c
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>1997-09-03 16:00:58 +0000
committerEric S. Raymond <esr@thyrsus.com>1997-09-03 16:00:58 +0000
commitcb98379a297424cf2573b2c81d676b64ade49141 (patch)
tree24e1ffab3423c85b0441a0cda9ab8100892567e2 /rfc822.c
parentf84776266d1d232ecf11f1cf57900a7abe000b54 (diff)
downloadfetchmail-cb98379a297424cf2573b2c81d676b64ade49141.tar.gz
fetchmail-cb98379a297424cf2573b2c81d676b64ade49141.tar.bz2
fetchmail-cb98379a297424cf2573b2c81d676b64ade49141.zip
Al Youngwerth's fix for RFC822.
svn path=/trunk/; revision=1280
Diffstat (limited to 'rfc822.c')
-rw-r--r--rfc822.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/rfc822.c b/rfc822.c
index 0976c701..6539977d 100644
--- a/rfc822.c
+++ b/rfc822.c
@@ -163,8 +163,9 @@ const char *hdr; /* header to be parsed, NUL to continue previous hdr */
else if (HEADER_END(hp))
{
state = ENDIT_ALL;
- while (isspace(*--tp))
- continue;
+ if (tp > address)
+ while (isspace(*--tp))
+ continue;
*++tp = '\0';
return(tp > address ? (tp = address) : (char *)NULL);
}