From: Fabian Keil Date: Sat, 18 Jul 2020 12:04:11 +0000 (+0200) Subject: receive_encrypted_request(): Use the socket-timeout when waiting for new data X-Git-Tag: v_3_0_29~265 X-Git-Url: http://www.privoxy.org/gitweb/?p=privoxy.git;a=commitdiff_plain;h=ed4b05105372a8745a0e4493f7fb0fe41742ab12 receive_encrypted_request(): Use the socket-timeout when waiting for new data Previously the keep-alive-timeout was being used which was inappropriate as we are waiting for data that belongs to the same request. Sponsored by: Robert Klemme --- diff --git a/jcc.c b/jcc.c index 511b36be..69c01808 100644 --- a/jcc.c +++ b/jcc.c @@ -2221,7 +2221,7 @@ static jb_err receive_encrypted_request(struct client_state *csp) { log_error(LOG_LEVEL_HEADER, "Reading encrypted headers"); if (!is_ssl_pending(&(csp->mbedtls_client_attr.ssl)) && - !data_is_available(csp->cfd, (int)csp->config->keep_alive_timeout)) + !data_is_available(csp->cfd, csp->config->socket_timeout)) { log_error(LOG_LEVEL_CONNECT, "Socket %d timed out while waiting for client headers", csp->cfd);