From 66de563482c0fd4324e1eae19809d2499e3c4fa8 Mon Sep 17 00:00:00 2001 From: Sylvestre Ledru Date: Fri, 10 Mar 2017 14:28:37 +0100 Subject: Improve code readbility ... by removing the else branch after a return, break or continue. Closes #1310 --- lib/sendf.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'lib/sendf.c') diff --git a/lib/sendf.c b/lib/sendf.c index 760169782..9435a30e6 100644 --- a/lib/sendf.c +++ b/lib/sendf.c @@ -565,10 +565,9 @@ CURLcode Curl_client_chop_write(struct connectdata *conn, failf(data, "Write callback asked for PAUSE when not supported!"); return CURLE_WRITE_ERROR; } - else - return pausewrite(data, type, ptr, len); + return pausewrite(data, type, ptr, len); } - else if(wrote != chunklen) { + if(wrote != chunklen) { failf(data, "Failed writing body (%zu != %zu)", wrote, chunklen); return CURLE_WRITE_ERROR; } @@ -652,8 +651,7 @@ CURLcode Curl_read_plain(curl_socket_t sockfd, #endif if(return_error) return CURLE_AGAIN; - else - return CURLE_RECV_ERROR; + return CURLE_RECV_ERROR; } /* we only return number of bytes read when we return OK */ -- cgit v1.2.3