fixed mutex issue in disk io thread

This commit is contained in:
Marcos Pinto 2007-06-17 14:21:44 +00:00
parent fa0a4813a6
commit 6ea7ddd7a0
1 changed files with 6 additions and 1 deletions

View File

@ -234,8 +234,13 @@ namespace libtorrent
try { if (handler) handler(ret, j); } try { if (handler) handler(ret, j); }
catch (std::exception&) {} catch (std::exception&) {}
if (j.buffer) m_pool.ordered_free(j.buffer); if (j.buffer)
{
l.lock();
m_pool.ordered_free(j.buffer);
}
} }
} }
} }