From 1baf40596abc449e5050f8b80b7fc9e08cd4bdf9 Mon Sep 17 00:00:00 2001 From: Arvid Norberg Date: Sat, 29 Jan 2011 20:45:13 +0000 Subject: [PATCH] put resume data in a subfolder in client_test --- examples/client_test.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/client_test.cpp b/examples/client_test.cpp index 0978441cc..963c2090e 100644 --- a/examples/client_test.cpp +++ b/examples/client_test.cpp @@ -608,7 +608,7 @@ void add_torrent(libtorrent::session& ses p.share_mode = share_mode; lazy_entry resume_data; - std::string filename = combine_path(save_path, t->name() + ".resume"); + std::string filename = combine_path(save_path, ".resume/" + t->name() + ".resume"); std::vector buf; if (load_file(filename.c_str(), buf, ec) == 0) @@ -774,7 +774,7 @@ void handle_alert(libtorrent::session& ses, libtorrent::alert* a { std::vector out; bencode(std::back_inserter(out), *p->resume_data); - save_file(combine_path(h.save_path(), h.name() + ".resume"), out); + save_file(combine_path(h.save_path(), ".resume/" + h.name() + ".resume"), out); if (std::find_if(handles.begin(), handles.end() , boost::bind(&torrent_entry::handle, boost::bind(&handles_t::value_type::second, _1)) == h) == handles.end()) ses.remove_torrent(h); @@ -1870,7 +1870,7 @@ int main(int argc, char* argv[]) torrent_handle h = rd->handle; std::vector out; bencode(std::back_inserter(out), *rd->resume_data); - save_file(combine_path(h.save_path(), h.name() + ".resume"), out); + save_file(combine_path(h.save_path(), ".resume/" + h.name() + ".resume"), out); } printf("\nsaving session state\n"); {