]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
urldata: remove the 'stream_was_rewound' connectdata struct member
authorDaniel Stenberg <daniel@haxx.se>
Thu, 5 Mar 2020 22:52:41 +0000 (23:52 +0100)
committerDaniel Stenberg <daniel@haxx.se>
Fri, 6 Mar 2020 07:15:35 +0000 (08:15 +0100)
... as it is never set anywhere.

Follow-up to 2f44e94ef
Closes #5046

lib/transfer.c
lib/urldata.h

index ead8b36db9bd1700425271b451322c541b312faa..f015b9120d3b86e6244f43c44a0b0009d5cda218 100644 (file)
@@ -890,7 +890,7 @@ static CURLcode readwrite_data(struct Curl_easy *data,
 
     } /* if(!header and data to read) */
 
-    if(conn->handler->readwrite && excess && !conn->bits.stream_was_rewound) {
+    if(conn->handler->readwrite && excess) {
       /* Parse the excess data */
       k->str += nread;
 
@@ -1234,9 +1234,7 @@ CURLcode Curl_readwrite(struct connectdata *conn,
   /* We go ahead and do a read if we have a readable socket or if
      the stream was rewound (in which case we have data in a
      buffer) */
-  if((k->keepon & KEEP_RECV) &&
-     ((select_res & CURL_CSELECT_IN) || conn->bits.stream_was_rewound)) {
-
+  if((k->keepon & KEEP_RECV) && (select_res & CURL_CSELECT_IN)) {
     result = readwrite_data(data, conn, k, &didwhat, done, comeback);
     if(result || *done)
       return result;
index e1348cf29b6285d03d812313021434d8e386584f..9e46265305aeb10473322276c09482fb1932cb04 100644 (file)
@@ -464,8 +464,6 @@ struct ConnectBits {
 #endif
   BIT(netrc);         /* name+password provided by netrc */
   BIT(userpwd_in_url); /* name+password found in url */
-  BIT(stream_was_rewound); /* The stream was rewound after a request read
-                              past the end of its response byte boundary */
   BIT(proxy_connect_closed); /* TRUE if a proxy disconnected the connection
                                 in a CONNECT request with auth, so that
                                 libcurl should reconnect and continue. */