Skip to content

Commit 79c5210

Browse files
committed
Make shutdown action more stable
1 parent 1ab08ea commit 79c5210

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

httplib.h

+2
Original file line numberDiff line numberDiff line change
@@ -8559,6 +8559,8 @@ inline void ssl_delete(std::mutex &ctx_mutex, SSL *ssl, socket_t sock,
85598559
setsockopt(sock, SOL_SOCKET, SO_RCVTIMEO,
85608560
reinterpret_cast<const void *>(&tv), sizeof(tv));
85618561

8562+
std::this_thread::sleep_for(std::chrono::milliseconds(100));
8563+
85628564
char buf[1];
85638565
if (SSL_peek(ssl, buf, 1) == 0 &&
85648566
SSL_get_error(ssl, 0) == SSL_ERROR_ZERO_RETURN) {

0 commit comments

Comments
 (0)