Skip to content

Commit

Permalink
Wait for cancel_cv on teardown()
Browse files Browse the repository at this point in the history
  • Loading branch information
dvsku committed Jun 22, 2024
1 parent 69c90bb commit b9f25e3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions include/libnetwrk/net/core/client/client.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,8 @@ namespace libnetwrk {

protected:
virtual void teardown() {
if (m_comp_connection.connection)
m_comp_connection.connection->stop();
m_context.cancel_cv.notify_all();
m_context.cancel_cv.wait_for_end();

m_comp_connection.stop_connection();

Expand Down

0 comments on commit b9f25e3

Please sign in to comment.