aboutsummaryrefslogtreecommitdiffstats
path: root/rfc822.c
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>1997-05-28 20:05:07 +0000
committerEric S. Raymond <esr@thyrsus.com>1997-05-28 20:05:07 +0000
commit5f683c2df3f6c04309d90851395083e9009c6206 (patch)
tree08d4c34afb24be3a8a0d050dce1a4459b141dfed /rfc822.c
parent758158639269eccfb361bf622c4702a384623982 (diff)
downloadfetchmail-5f683c2df3f6c04309d90851395083e9009c6206.tar.gz
fetchmail-5f683c2df3f6c04309d90851395083e9009c6206.tar.bz2
fetchmail-5f683c2df3f6c04309d90851395083e9009c6206.zip
Yet more pparsing improvements.
svn path=/trunk/; revision=1038
Diffstat (limited to 'rfc822.c')
-rw-r--r--rfc822.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/rfc822.c b/rfc822.c
index c9dc37b9..6e9dd1a9 100644
--- a/rfc822.c
+++ b/rfc822.c
@@ -194,6 +194,7 @@ const char *hdr; /* header to be parsed, NUL to continue previous hdr */
else if (*hp == '(') /* address comment -- ignore */
{
parendepth = 1;
+ oldstate = SKIP_JUNK;
state = INSIDE_PARENS;
}
else if (*hp == '<') /* begin <address> */
@@ -221,6 +222,7 @@ const char *hdr; /* header to be parsed, NUL to continue previous hdr */
else if (*hp == '(') /* beginning of comment */
{
parendepth = 1;
+ oldstate = BARE_ADDRESS;
state = INSIDE_PARENS;
}
else if (*hp == '<') /* beginning of real address */
@@ -248,7 +250,7 @@ const char *hdr; /* header to be parsed, NUL to continue previous hdr */
else if (*hp == ')')
--parendepth;
if (parendepth == 0)
- state = SKIP_JUNK;
+ state = oldstate;
break;
case INSIDE_BRACKETS: /* possible <>-enclosed address */