]> granicus.if.org Git - curl/commitdiff
libcurl: stop reading from paused transfers
authorSangamkar <dheerajs@netapp.com>
Mon, 5 Nov 2018 23:29:55 +0000 (15:29 -0800)
committerDaniel Stenberg <daniel@haxx.se>
Tue, 6 Nov 2018 18:07:17 +0000 (19:07 +0100)
In the transfer loop it would previously not acknwledge the pause bit
and continue until drained or loop ended.

Closes #3240

lib/transfer.c

index 05ba862c2705470af95bb8886e26f6bdb7d2ed34..de6043d7d340226493ef1fb7fc9d9569afa8c0f6 100644 (file)
@@ -844,6 +844,11 @@ static CURLcode readwrite_data(struct Curl_easy *data,
       k->keepon &= ~KEEP_RECV;
     }
 
+    if(k->keepon & KEEP_RECV_PAUSE) {
+      /* this is a paused transfer */
+      break;
+    }
+
   } while(data_pending(conn) && maxloops--);
 
   if(maxloops <= 0) {