mirror of
https://github.com/curl/curl.git
synced 2026-07-30 05:48:03 +03:00
conncache: only allow multiplexing within same multi handle
Connections that are used for HTTP/1.1 Pipelining or HTTP/2 multiplexing only get additional transfers added to them if the existing connection is held by the same multi or easy handle. libcurl does not support doing HTTP/2 streams in different threads using a shared connection. Closes #2152
This commit is contained in:
parent
415b8dff8e
commit
ea3a5d07dc
2 changed files with 14 additions and 2 deletions
|
|
@ -1264,6 +1264,11 @@ ConnectionExists(struct Curl_easy *data,
|
|||
already in use so we skip it */
|
||||
continue;
|
||||
|
||||
if((check->inuse) && (check->data->multi != needle->data->multi))
|
||||
/* this could be subject for pipeline/multiplex use, but only
|
||||
if they belong to the same multi handle */
|
||||
continue;
|
||||
|
||||
if(needle->localdev || needle->localport) {
|
||||
/* If we are bound to a specific local end (IP+port), we must not
|
||||
re-use a random other one, although if we didn't ask for a
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue