diff options
author | ltoetsch <> | 2001-03-15 11:10:53 +0000 |
---|---|---|
committer | ltoetsch <> | 2001-03-15 11:10:53 +0000 |
commit | 17d48d42d690475b60be3b1e2cfdb30bfff54e83 (patch) | |
tree | ef79db12a04eb342ce0c60eb002c1911fc3fbb95 /mail2.c | |
parent | 700387144db81be8ed39c0906ee22cb24ce794c4 (diff) | |
download | lcd4linux-17d48d42d690475b60be3b1e2cfdb30bfff54e83.tar.gz |
[lcd4linux @ 2001-03-15 11:10:53 by ltoetsch]
added quit/logout to pop/imap
Diffstat (limited to 'mail2.c')
-rw-r--r-- | mail2.c | 9 |
1 files changed, 8 insertions, 1 deletions
@@ -1,4 +1,4 @@ -/* $Id: mail2.c,v 1.1 2001/03/14 13:19:29 ltoetsch Exp $ +/* $Id: mail2.c,v 1.2 2001/03/15 11:10:53 ltoetsch Exp $ * * mail: pop3, imap functions * @@ -20,6 +20,9 @@ * * * $Log: mail2.c,v $ + * Revision 1.2 2001/03/15 11:10:53 ltoetsch + * added quit/logout to pop/imap + * * Revision 1.1 2001/03/14 13:19:29 ltoetsch * Added pop3/imap4 mail support * @@ -203,6 +206,8 @@ static int check_imap4(char *user, char *pass, char *machine, close(fd); return -1; } + strcpy(buf,". LOGOUT\r\n"); + wr_rd(fd, buf, "", "LOGOUT", machine, port); close(fd); return 0; } @@ -248,6 +253,8 @@ static int check_pop3(char *user, char *pass, char *machine, sscanf(buf, "+OK %d", unseen); *unseen = *total - *unseen; } + strcpy(buf, "QUIT\r\n"); + wr_rd(fd, buf, "+OK", "Quit", machine, port); close(fd); return 0; } |