fix iterator issue in client_test

This commit is contained in:
Arvid Norberg 2011-11-01 21:08:21 +00:00
parent 4559980c92
commit 92661b2a71
1 changed files with 1 additions and 1 deletions

View File

@ -1592,10 +1592,10 @@ int main(int argc, char* argv[])
, boost::bind(&handles_t::value_type::second, _1) == h);
if (i != files.end())
{
files.erase(i);
error_code ec;
remove(combine_path(monitor_dir, i->first), ec);
if (ec) printf("failed to delete .torrent file: %s\n", ec.message().c_str());
files.erase(i);
}
if (h.is_valid())
ses.remove_torrent(h, session::delete_files);