From 536e7eb7f2ed27109423bea95c4c6ed41fbf040a Mon Sep 17 00:00:00 2001 From: yhirose Date: Sun, 25 Oct 2020 20:22:39 -0400 Subject: [PATCH] Revert "Fix #697". (It broke unit test...) This reverts commit 6d66721ba14f862983dad6bdf269af3c0a343cb1. --- httplib.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/httplib.h b/httplib.h index 3f2e57b..d2795a9 100644 --- a/httplib.h +++ b/httplib.h @@ -6104,12 +6104,12 @@ inline bool SSLClient::initialize_ssl(Socket &socket) { } inline void SSLClient::close_socket(Socket &socket, bool process_socket_ret) { + detail::close_socket(socket.sock); + socket_.sock = INVALID_SOCKET; if (socket.ssl) { detail::ssl_delete(ctx_mutex_, socket.ssl, process_socket_ret); socket_.ssl = nullptr; } - detail::close_socket(socket.sock); - socket_.sock = INVALID_SOCKET; } inline bool