back port check to not destruct session_impl from its own thread

This commit is contained in:
Arvid Norberg
2013-09-29 19:37:57 +00:00
parent a623c4c41c
commit 4ac3d286a5
2 changed files with 10 additions and 0 deletions

View File

@@ -5940,6 +5940,8 @@ retry:
session_impl::~session_impl()
{
TORRENT_ASSERT(is_not_network_thread());
m_io_service.post(boost::bind(&session_impl::abort, this));
// we need to wait for the disk-io thread to