diff options
author | Eric S. Raymond <esr@thyrsus.com> | 1996-10-30 14:25:15 +0000 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 1996-10-30 14:25:15 +0000 |
commit | a06e308306ed41ca257eabc7e522b03cfbe1c53b (patch) | |
tree | 9d3faf5d76570b70d48c0414e2cfdfe4909aa70e /driver.c | |
parent | 7ecfbbff9c1f4211fe4e86cec10c42df3f951b2d (diff) | |
download | fetchmail-a06e308306ed41ca257eabc7e522b03cfbe1c53b.tar.gz fetchmail-a06e308306ed41ca257eabc7e522b03cfbe1c53b.tar.bz2 fetchmail-a06e308306ed41ca257eabc7e522b03cfbe1c53b.zip |
Handle multiple comma-separated local names correctly.
svn path=/trunk/; revision=434
Diffstat (limited to 'driver.c')
-rw-r--r-- | driver.c | 5 |
1 files changed, 2 insertions, 3 deletions
@@ -117,8 +117,6 @@ const char *host; /* server hostname */ state = 5; else if (isspace(*from)) state = 2; - else if (*from == ',') - tokencount = 0; break; case 2: /* found a token boundary -- reset without copying */ @@ -185,11 +183,12 @@ const char *host; /* server hostname */ strcpy(buf, "@"); strcat(buf, host); buf += strlen(buf); + tokencount = 0; state = 1; } /* a single local name alone on the line */ - else if (*from == '\n' && tokencount == 0) + else if (*from == '\n' && tokencount == 1) { strcpy(buf, "@"); strcat(buf, host); |