mirror of
https://github.com/yhirose/cpp-httplib.git
synced 2026-11-17 19:30:54 +00:00
Close the tunnel when the TLS handshake through a proxy fails
SSLClient::setup_proxy_connection() left the socket open when the TLS handshake inside the CONNECT tunnel failed, so the client kept a connection with no TLS session on it. Only the next request's reuse check closed it, because tls::is_peer_closed() reports a missing session as closed. Close it where the handshake fails, as ensure_socket_connection() does for a direct connection.
This commit is contained in:
1 parent
f57672b390
commit
1b40ce850b
2 files changed
+36