aboutsummaryrefslogtreecommitdiffstats
path: root/pop3.c
diff options
context:
space:
mode:
Diffstat (limited to 'pop3.c')
-rw-r--r--pop3.c10
1 files changed, 8 insertions, 2 deletions
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)