mirror of
https://github.com/curl/curl.git
synced 2026-04-14 22:41:40 +03:00
lib: upgrade/multiplex handling
Improvements around HTTP Upgrade: and multiplex hanndling: * add `Curl_conn_set_multiplex()` to set connection's multiplex bit and trigger "connchanged" events * call `Curl_conn_set_multiplex()` in filters' `CF_CTRL_CONN_INFO_UPDATE` implementation where other connection properties are updated. This prevents connection updates before the final filter chain is chosen. * rename enum `UPGR101_INIT` to `UPGR101_NONE` * rename connection bit `asks_multiplex` to `upgrade_in_progress` * trigger "connchanged" when `upgrade_in_progress` clears * rename `WebSockets` to `WebSocket` as it is the common term used in documentation Closes #18227
This commit is contained in:
parent
943166fed3
commit
b3fc692568
13 changed files with 90 additions and 65 deletions
|
|
@ -621,3 +621,13 @@ out:
|
|||
Curl_resolv_unlink(data, &data->state.dns[sockindex]);
|
||||
return result;
|
||||
}
|
||||
|
||||
void Curl_conn_set_multiplex(struct connectdata *conn)
|
||||
{
|
||||
if(!conn->bits.multiplex) {
|
||||
conn->bits.multiplex = TRUE;
|
||||
if(conn->attached_multi) {
|
||||
Curl_multi_connchanged(conn->attached_multi);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue