From c0de8b3ade0ae557755003482a4b67b350efedd3 Mon Sep 17 00:00:00 2001 From: "Eric S. Raymond" Date: Wed, 9 Oct 1996 18:26:29 +0000 Subject: Let POP3 pick up the message length. svn path=/trunk/; revision=272 --- pop3.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'pop3.c') diff --git a/pop3.c b/pop3.c index 30cd0a08..84eb9d1d 100644 --- a/pop3.c +++ b/pop3.c @@ -178,8 +178,14 @@ int socket; int number; int *lenp; { - *lenp = 0; - return(gen_transact(socket, "RETR %d", number)); + int ok; + char buf [POPBUFSIZE+1]; + + gen_send(socket, "RETR %d", number); + if ((ok = pop3_ok(socket, buf)) != 0) + return(ok); + *lenp = atoi(buf); + return(0); } static pop3_delete(socket, queryctl, number) -- cgit v1.2.3