lt sync 3209

This commit is contained in:
Andrew Resch 2009-01-25 02:10:39 +00:00
parent 082dea9b80
commit 5697376caa
3 changed files with 3 additions and 3 deletions

View File

@ -9,7 +9,7 @@ using namespace boost::python;
template<class T1, class T2> template<class T1, class T2>
struct pair_to_tuple struct pair_to_tuple
{ {
static PyObject* convert(const std::pair<T1, T2>& p) static PyObject* convert(const std::pair<int, int>& p)
{ {
return incref(make_tuple(p.first, p.second).ptr()); return incref(make_tuple(p.first, p.second).ptr());
} }

View File

@ -57,7 +57,8 @@ namespace libtorrent
lru_file_entry e = *i; lru_file_entry e = *i;
e.last_use = time_now(); e.last_use = time_now();
if (e.key != st) if (e.key != st && ((e.mode & file::rw_mask) != file::read_only
|| (m & file::rw_mask) != file::read_only))
{ {
// this means that another instance of the storage // this means that another instance of the storage
// is using the exact same file. // is using the exact same file.

View File

@ -2163,7 +2163,6 @@ namespace aux {
mutex_t::scoped_lock l(m_mutex); mutex_t::scoped_lock l(m_mutex);
if (m_dht) e = m_dht->state(); if (m_dht) e = m_dht->state();
done = true; done = true;
l.unlock();
c.notify_all(); c.notify_all();
} }