summaryrefslogtreecommitdiff
path: root/lib/pingpong.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2012-11-04 18:22:48 +0100
committerDaniel Stenberg <daniel@haxx.se>2012-11-04 19:05:39 +0100
commitb2954e66e87be7414a4508f8167ca531e653bea8 (patch)
treef7efa072bdae808c52f7bded50d1a75cde2df82f /lib/pingpong.c
parent7c0f201075029a7c87c5cfe84f0405bb08441fbf (diff)
downloadcurl-b2954e66e87be7414a4508f8167ca531e653bea8.tar.gz
FTP: prevent the multi interface from blocking
As pointed out in Bug report #3579064, curl_multi_perform() would wrongly use a blocking mechanism internally for some commands which could lead to for example a very long block if the LIST response never showed. The solution was to make sure to properly continue to use the multi interface non-blocking state machine. The new test 1501 verifies the fix. Bug: http://curl.haxx.se/bug/view.cgi?id=3579064 Reported by: Guido Berhoerster
Diffstat (limited to 'lib/pingpong.c')
-rw-r--r--lib/pingpong.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/pingpong.c b/lib/pingpong.c
index c10894654..85a7a45af 100644
--- a/lib/pingpong.c
+++ b/lib/pingpong.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2011, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2012, Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -424,6 +424,9 @@ CURLcode Curl_pp_readresp(curl_socket_t sockfd,
it may actually contain another end of response already! */
clipamount = gotbytes - i;
restart = TRUE;
+ DEBUGF(infof(data, "Curl_pp_readresp_ %d bytes of trailing "
+ "server response left\n",
+ (int)clipamount));
}
else if(keepon) {