MCPcopy Create free account
hub / github.com/apache/httpd / set_ping_timeout

Function set_ping_timeout

modules/http2/h2_proxy_session.c:96–107  ·  view source on GitHub ↗

* The H2_PING connection sub-state: a state independant of the H2_SESSION state * of the connection: * - H2_PING_ST_NONE: no interference with request handling, ProxyTimeout in effect. * When entered, all suspended streams are unsuspended again. * - H2_PING_ST_AWAIT_ANY: new requests are suspended, a possibly configured "ping" * timeout is in effect. Any frame received transits to H2_PING

Source from the content-addressed store, hash-verified

94 * when expecting PING answers.
95 */
96static void set_ping_timeout(h2_proxy_session *session)
97{
98 if (session->ping_timeout != -1 && session->save_timeout == -1) {
99 apr_socket_t *socket = NULL;
100
101 socket = ap_get_conn_socket(session->c);
102 if (socket) {
103 apr_socket_timeout_get(socket, &session->save_timeout);
104 apr_socket_timeout_set(socket, session->ping_timeout);
105 }
106 }
107}
108
109static void unset_ping_timeout(h2_proxy_session *session)
110{

Callers 1

enter_ping_stateFunction · 0.85

Calls 1

ap_get_conn_socketFunction · 0.85

Tested by

no test coverage detected