summaryrefslogtreecommitdiff
path: root/lib/pipeline.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2018-07-17 00:29:11 +0200
committerDaniel Stenberg <daniel@haxx.se>2018-07-20 22:58:42 +0200
commit7b9bc96c7716f34dbd1f525aefb77d74b8b0f528 (patch)
tree3815a1f09eb5c3fcf6ea1fb81aa1cceb1b28d197 /lib/pipeline.c
parent73af7bcd617a8c0312bd8a083daa5a8fad2c794e (diff)
downloadcurl-7b9bc96c7716f34dbd1f525aefb77d74b8b0f528.tar.gz
http2: several cleanups
- separate easy handle from connections better - added asserts on a number of places - added sanity check of pipelines for debug builds Closes #2751
Diffstat (limited to 'lib/pipeline.c')
-rw-r--r--lib/pipeline.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/pipeline.c b/lib/pipeline.c
index 068940920..8de3babd7 100644
--- a/lib/pipeline.c
+++ b/lib/pipeline.c
@@ -6,7 +6,7 @@
* \___|\___/|_| \_\_____|
*
* Copyright (C) 2013, Linus Nielsen Feltzing, <linus@haxx.se>
- * Copyright (C) 2013 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 2013 - 2018, 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
@@ -110,8 +110,8 @@ CURLcode Curl_add_handle_to_pipeline(struct Curl_easy *handle,
pipeline = &conn->send_pipe;
result = addHandleToPipeline(handle, pipeline);
-
- if(pipeline == &conn->send_pipe && sendhead != conn->send_pipe.head) {
+ if((conn->bundle->multiuse == BUNDLE_PIPELINING) &&
+ (pipeline == &conn->send_pipe && sendhead != conn->send_pipe.head)) {
/* this is a new one as head, expire it */
Curl_pipeline_leave_write(conn); /* not in use yet */
Curl_expire(conn->send_pipe.head->ptr, 0, EXPIRE_RUN_NOW);