aboutsummaryrefslogtreecommitdiff
path: root/lib/url.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2008-06-19 08:31:22 +0000
committerDaniel Stenberg <daniel@haxx.se>2008-06-19 08:31:22 +0000
commitfb2e71b9bd352bca7e3a5533c69bd236132a5d7a (patch)
treefe06a50b4d75ecdd94aa2cc2f484c6a4bf88c902 /lib/url.c
parent68b67e24f26fbfaac2f869145b91110d5b5b1b69 (diff)
- Dengminwen found a bug in the connection re-use function when using the
multi interface with pipelining enabled as it would wrongly check for, detect and close "dead connections" even though that connection was already in use!
Diffstat (limited to 'lib/url.c')
-rw-r--r--lib/url.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/url.c b/lib/url.c
index a7f1a0c1a..6391edb28 100644
--- a/lib/url.c
+++ b/lib/url.c
@@ -2511,9 +2511,10 @@ ConnectionExists(struct SessionHandle *data,
}
if(match) {
- if(pipeLen == 0) {
- /* The check for a dead socket makes sense only if there
- are no handles in pipeline */
+ if(!pipeLen && !check->inuse) {
+ /* The check for a dead socket makes sense only if there are no
+ handles in pipeline and the connection isn't already marked in
+ use */
bool dead = SocketIsDead(check->sock[FIRSTSOCKET]);
if(dead) {
check->data = data;