]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
Curl_pp_flushsend: skip superfluous assignment
authorDaniel Stenberg <daniel@haxx.se>
Thu, 23 Oct 2014 20:46:10 +0000 (22:46 +0200)
committerDaniel Stenberg <daniel@haxx.se>
Fri, 24 Oct 2014 06:23:19 +0000 (08:23 +0200)
Detected by cppcheck.

lib/pingpong.c

index adfb50a63db4d0372ca03175343a28f0618f6dc1..121693daa891b556811e6ebf997e70dba6282d23 100644 (file)
@@ -476,11 +476,9 @@ CURLcode Curl_pp_flushsend(struct pingpong *pp)
   /* we have a piece of a command still left to send */
   struct connectdata *conn = pp->conn;
   ssize_t written;
-  CURLcode result = CURLE_OK;
   curl_socket_t sock = conn->sock[FIRSTSOCKET];
-
-  result = Curl_write(conn, sock, pp->sendthis + pp->sendsize -
-                      pp->sendleft, pp->sendleft, &written);
+  CURLcode result = Curl_write(conn, sock, pp->sendthis + pp->sendsize -
+                               pp->sendleft, pp->sendleft, &written);
   if(result)
     return result;