merged client_test fix from libtorrent_aio
This commit is contained in:
@@ -1685,7 +1685,10 @@ int main(int argc, char* argv[])
|
|||||||
if (i != files.end())
|
if (i != files.end())
|
||||||
{
|
{
|
||||||
error_code ec;
|
error_code ec;
|
||||||
remove(combine_path(monitor_dir, i->first), ec);
|
std::string path;
|
||||||
|
if (is_complete(i->first)) path = i->first;
|
||||||
|
else path = combine_path(monitor_dir, i->first);
|
||||||
|
remove(path, ec);
|
||||||
if (ec) printf("failed to delete .torrent file: %s\n", ec.message().c_str());
|
if (ec) printf("failed to delete .torrent file: %s\n", ec.message().c_str());
|
||||||
files.erase(i);
|
files.erase(i);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user