got rid of the last recursive mutexes. abstracted the threading primitives (and switched over to use asio's internal ones).

This commit is contained in:
Arvid Norberg
2009-10-20 02:49:56 +00:00
parent a5fb1b3455
commit 8a5b7d5d36
41 changed files with 449 additions and 484 deletions

View File

@@ -101,18 +101,7 @@ bool print_alerts(libtorrent::session& ses, char const* name
void test_sleep(int millisec)
{
boost::xtime xt;
boost::xtime_get(&xt, boost::TIME_UTC);
boost::uint64_t nanosec = (millisec % 1000) * 1000000 + xt.nsec;
int sec = millisec / 1000;
if (nanosec > 1000000000)
{
nanosec -= 1000000000;
sec++;
}
xt.nsec = nanosec;
xt.sec += sec;
boost::thread::sleep(xt);
libtorrent::sleep(millisec);
}
void stop_web_server(int port)