diff options
author | Eric S. Raymond <esr@thyrsus.com> | 2002-10-18 15:29:05 +0000 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 2002-10-18 15:29:05 +0000 |
commit | 0f19cf5f3f3ee4637609c61d0ac2b862d82204ad (patch) | |
tree | bc19ce1adf1b4ce03a0c8fce90807570efead6c7 /driver.c | |
parent | a63e7031d34003daa4ccf308d8406fb0d9eeca3b (diff) | |
download | fetchmail-0f19cf5f3f3ee4637609c61d0ac2b862d82204ad.tar.gz fetchmail-0f19cf5f3f3ee4637609c61d0ac2b862d82204ad.tar.bz2 fetchmail-0f19cf5f3f3ee4637609c61d0ac2b862d82204ad.zip |
Sunil Shetye's header-read fix.
svn path=/trunk/; revision=3746
Diffstat (limited to 'driver.c')
-rw-r--r-- | driver.c | 16 |
1 files changed, 15 insertions, 1 deletions
@@ -493,11 +493,25 @@ static int fetch_messages(int mailserver_socket, struct query *ctl, err = readheaders(mailserver_socket, len, msgsizes[num-1], ctl, num); if (err == PS_RETAINED) - suppress_readbody = suppress_forward = suppress_delete = retained = TRUE; + { + suppress_forward = suppress_delete = retained = TRUE; + /* do not read the body only if the underlying protocol + * allows the body to be fetched separately */ + if (ctl->server.base_protocol->fetch_body) + suppress_readbody = TRUE; + } else if (err == PS_TRANSIENT) + { suppress_delete = suppress_forward = TRUE; + if (ctl->server.base_protocol->fetch_body) + suppress_readbody = TRUE; + } else if (err == PS_REFUSED) + { suppress_forward = TRUE; + if (ctl->server.base_protocol->fetch_body) + suppress_readbody = TRUE; + } #if 0 /* * readheaders does not read the body when it |