Browse Source

Stop async worker at correct place

adaptive-webui-19844
Vladimir Golovnev (Glassez) 2 years ago
parent
commit
40258f6a2f
No known key found for this signature in database
GPG Key ID: 52A2C7DEE2DFA6F7
  1. 2
      src/base/bittorrent/sessionimpl.cpp

2
src/base/bittorrent/sessionimpl.cpp

@ -627,6 +627,8 @@ SessionImpl::~SessionImpl()
// we delete lt::session // we delete lt::session
delete Net::PortForwarder::instance(); delete Net::PortForwarder::instance();
// We must stop "async worker" only after deletion
// of all the components that could potentially use it
m_asyncWorker->clear(); m_asyncWorker->clear();
m_asyncWorker->waitForDone(); m_asyncWorker->waitForDone();

Loading…
Cancel
Save