Skip to content

Commit 563fcc6

Browse files
author
Peter Thorson
committed
wrap TLS async_shutdown in a strand references zaphoyd#459 zaphoyd#466
1 parent b6014cc commit 563fcc6

File tree

1 file changed

+5
-1
lines changed
  • websocketpp/transport/asio/security

1 file changed

+5
-1
lines changed

websocketpp/transport/asio/security/tls.hpp

+5-1
Original file line numberDiff line numberDiff line change
@@ -326,7 +326,11 @@ class connection : public lib::enable_shared_from_this<connection> {
326326
}
327327

328328
void async_shutdown(socket::shutdown_handler callback) {
329-
m_socket->async_shutdown(callback);
329+
if (m_strand) {
330+
m_socket->async_shutdown(m_strand->wrap(callback));
331+
} else {
332+
m_socket->async_shutdown(callback);
333+
}
330334
}
331335

332336
/// Translate any security policy specific information about an error code

0 commit comments

Comments
 (0)