I'm getting a what I'd term a bug in version 6.2.1 and later. I'm
running Debian Testing (fetchmail 6.2.1) and have downloaded the 6.2.2
source.
The problem is this: I'm getting email where fetchmail is returning an
error containing the text
incorrect header found while scanning headers
and then fetchmail leaves the mail on the pop server. Unfortunately,
there is no way to coerce fetchmail to retrieve or kill the mail on the
pop server. It's effectively "wedged" up there.
I've examined some of the offending emails, and apparently someone is
creating HTML email (I know, I know) which contains "Content-Type" tags
and such in the headers prior to the first blank line (header
delimiter). Of course, this is non-RFC822.
I've looked at the source, and in the file transact.c, function
readheaders(), there is a section starting at line 508 that explains
what's happening here. Apparently, when fetchmail sees these malformed
headers, it simply marks the mail to be retained on the server. The
explanation in code comments is that, without this check, fetchmail will
segfault.
I don't know why fetchmail would segfault, but the overall effect here
is that I can't unwedge this mail without going onto the webmail
interface for my pop server (yuk). I'd hand you a patch, but 1) I'm not
that great a programmer, and 2) I don't know anywhere near enough to
start stomping around in code that handles RFC822 issues.
Paul