fetchmail-6.2.5 bug in FreeBSD-current

Giorgos Keramidas keramida at ceid.upatras.gr
Sun Mar 28 18:07:16 PST 2004


On 2004-03-28 20:07, Stephen McKay <smckay at internode.on.net> wrote:
> On Saturday, 27th March 2004, Giorgos Keramidas wrote:
> >Looking more carefully at the check, I found out that you're absolutely
> >right.  The check's logic is fine as it is, it's the way that the
> >pop3_getpartialsizes() function is called that is broken.
>
> When I ran into this problem, I found a patch that is supposed to do
> the right thing (ie not try to fetch multiple sizes when that isn't
> possible).  I'm pretty sure I found it in the fetchmail list archives.
> [...] But I didn't bother to try the patch since adding
> "fetchsizelimit 1" to .fetchmailrc is a successful workaround.

Oh well, that was *so* very on the spot.  I searched for the patch and
found a siggestion for fetchsizelimit = 1, along with a note that POP3
works fine -- it's only APOP and RPOP that are broken (I should have
guessed after looking at the code of fetchmail/driver.c, but somehow
I failed to remember that I'm using APOP).

The solution suggested by Sunil Shetye who wrote the nearby parts of
driver.c was to set fetchsizelimit to 1 OR change driver.c to make sure
that fetchsizelimit is automagically set to 1 for APOP and RPOP too.

The following little diff fixed things for me, without having to make
any changes to existing config files of my accounts or the accounts of
other people:

%%
--- driver.c.orig	Sun Mar 28 13:29:15 2004
+++ driver.c	Sun Mar 28 13:49:42 2004
@@ -429,7 +429,8 @@
 	/* for POP3, we can get the size of one mail only! Unfortunately, this
 	 * protocol specific test cannot be done elsewhere as the protocol
 	 * could be "auto". */
-	if (ctl->server.protocol == P_POP3)
+	if (ctl->server.protocol == P_POP3 || ctl->server.protocol == P_APOP ||
+	    ctl->server.protocol == P_RPOP)
 	    fetchsizelimit = 1;
 
 	/* Time to allocate memory to store the sizes */
%%

Many thanks for pointing me to the right direction :-)

- Giorgos



More information about the freebsd-bugs mailing list