diff --git a/src/rpc/websocket_api.cpp b/src/rpc/websocket_api.cpp index 0798f8f..da97a9e 100644 --- a/src/rpc/websocket_api.cpp +++ b/src/rpc/websocket_api.cpp @@ -74,7 +74,10 @@ websocket_api_connection::websocket_api_connection( const std::shared_ptrclosed.connect( [this](){ closed(); } ); + _connection->closed.connect( [this](){ + closed(); + _connection = nullptr; + } ); } variant websocket_api_connection::send_call(