From b56c9eb48e3cad89d35963f0934571bf5de48ab2 Mon Sep 17 00:00:00 2001 From: Steve Holme Date: Tue, 12 Feb 2013 18:08:48 +0000 Subject: pingpong: Optimised the endofresp() function Reworked the pp->endofresp() function so that the conndata, line and line length are passed down to it just as with Curl_client_write() rather than each implementation of the function having to query these values. Additionally changed the int return type to bool as this is more representative of the function's usage. --- lib/pop3.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'lib/pop3.c') diff --git a/lib/pop3.c b/lib/pop3.c index 398db01db..263d8703a 100644 --- a/lib/pop3.c +++ b/lib/pop3.c @@ -220,11 +220,9 @@ static void pop3_to_pop3s(struct connectdata *conn) given string, but also detects the APOP timestamp from the server greeting as well as the supported authentication types and allowed SASL mechanisms from the CAPA response. */ -static int pop3_endofresp(struct pingpong *pp, int *resp) +static bool pop3_endofresp(struct connectdata *conn, char *line, size_t len, + int *resp) { - char *line = pp->linestart_resp; - size_t len = strlen(pp->linestart_resp); - struct connectdata *conn = pp->conn; struct pop3_conn *pop3c = &conn->proto.pop3c; size_t wordlen; size_t i; -- cgit v1.2.3