aboutsummaryrefslogtreecommitdiffstats
path: root/driver.c
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>1997-09-24 16:27:37 +0000
committerEric S. Raymond <esr@thyrsus.com>1997-09-24 16:27:37 +0000
commitc5b468066e7dcf28f94a65bb56189afb87ed48a4 (patch)
tree2ad39346f504a0b7c34fbe68b9498f1a4496b46c /driver.c
parent264d154656b263c434f6de3700b5b06a35206673 (diff)
downloadfetchmail-c5b468066e7dcf28f94a65bb56189afb87ed48a4.tar.gz
fetchmail-c5b468066e7dcf28f94a65bb56189afb87ed48a4.tar.bz2
fetchmail-c5b468066e7dcf28f94a65bb56189afb87ed48a4.zip
Deal with Post Office/NT.
svn path=/trunk/; revision=1402
Diffstat (limited to 'driver.c')
-rw-r--r--driver.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/driver.c b/driver.c
index 53a69523..5d8e2a95 100644
--- a/driver.c
+++ b/driver.c
@@ -1619,6 +1619,23 @@ const struct method *proto; /* protocol method table */
flag suppress_forward = FALSE;
flag retained = FALSE;
+ /*
+ * This check copes with Post Office/NT's annoying habit
+ * of randomly prepending bogus LIST items of length -1.
+ * Patrick Audley <paudley@pobox.com> tells us:
+ * LIST shows a size of -1, RETR and TOP return
+ * "-ERR System error - couldn't open message", and DELE
+ * succeeds but doesn't actually delete the message.
+ */
+ if (msgsizes && msgsizes[num-1] == -1)
+ {
+ if (outlevel >= O_VERBOSE)
+ error(0, 0,
+ "Skipping message %d, length -1",
+ num - 1);
+ continue;
+ }
+
/* we may want to reject this message if it's old */
if (!fetch_it)
{