1
0
mirror of https://github.com/moparisthebest/curl synced 2024-08-13 17:03:50 -04:00

Make Curl_pop3_write() additionally truncate trailing POP3_EOB from received

string buffer, otherwise Curl_client_write() call with zero size would write
to the end of string buffer including matched POP3_EOB.
This commit is contained in:
Yang Tse 2010-01-30 05:22:30 +00:00
parent 6ebd71d186
commit 715e3a806f

View File

@ -935,6 +935,7 @@ CURLcode Curl_pop3_write(struct connectdata *conn,
pop3c->eob += check;
if(pop3c->eob == POP3_EOB_LEN) {
/* full match, the transfer is done! */
str[nread - check] = '\0';
nread -= check;
k->keepon &= ~KEEP_RECV;
pop3c->eob = 0;