Commit 7e23243420524a3848ad9a112c8df364197a00d1

Authored by Patric Stout
1 parent 1f70ca5d

chore: name the different threads to make diagnostics easier

Showing 1 changed file with 2 additions and 0 deletions
src/Connection.cpp
... ... @@ -22,6 +22,8 @@ TrueMQTT::Client::Impl::Connection::Connection(Client::Impl &impl)
22 22 m_thread_write(&Connection::runWrite, this),
23 23 m_backoff(impl.m_connection_backoff)
24 24 {
  25 + pthread_setname_np(m_thread_read.native_handle(), "TrueMQTT::Read");
  26 + pthread_setname_np(m_thread_write.native_handle(), "TrueMQTT::Write");
25 27 }
26 28  
27 29 TrueMQTT::Client::Impl::Connection::~Connection()
... ...