fix for when aborting torrents that are being checked. Fix in client_test when removing torrents that are checking.

This commit is contained in:
Arvid Norberg
2008-11-17 01:19:46 +00:00
parent de93105d51
commit f503bbfe86
6 changed files with 44 additions and 1 deletions

View File

@@ -656,6 +656,13 @@ void handle_alert(libtorrent::session& ses, libtorrent::alert* a
ses.remove_torrent(h);
}
}
else if (save_resume_data_failed_alert* p = dynamic_cast<save_resume_data_failed_alert*>(a))
{
torrent_handle h = p->handle;
if (std::find_if(handles.begin(), handles.end()
, bind(&handles_t::value_type::second, _1) == h) == handles.end())
ses.remove_torrent(h);
}
}
static char const* state_str[] =