diff --git a/examples/make_torrent.cpp b/examples/make_torrent.cpp index 37fbd1527..3117e7b89 100644 --- a/examples/make_torrent.cpp +++ b/examples/make_torrent.cpp @@ -125,7 +125,8 @@ OPTIONS: the specified url -t url adds the specified tracker to the torrent. For multiple trackers, specify more - -t options + -t options. Specify a dash character "-" as a tracker to indicate + the following trackers should be in a higher tier. -c comment sets the comment to the specified string -C creator sets the created-by field to the specified string -p bytes enables padding files. Files larger @@ -288,8 +289,8 @@ int main(int argc_, char const* argv_[]) try lt::create_torrent t(fs, piece_size, pad_file_limit, flags); int tier = 0; for (std::string const& tr : trackers) { - t.add_tracker(tr, tier); - ++tier; + if (tr == "-") ++tier; + else t.add_tracker(tr, tier); } for (std::string const& ws : web_seeds)