Fix dht_put.

This commit is contained in:
Thomas Yuan 2015-08-27 23:45:29 -04:00
parent cc29a99c90
commit 2685674eb9
1 changed files with 3 additions and 0 deletions

View File

@ -159,10 +159,13 @@ int main(int argc, char* argv[])
} }
settings_pack sett; settings_pack sett;
sett.set_bool(settings_pack::enable_dht, false);
sett.set_int(settings_pack::alert_mask, 0xffffffff); sett.set_int(settings_pack::alert_mask, 0xffffffff);
lt::session s(sett); lt::session s(sett);
s.add_dht_router(std::pair<std::string, int>("router.utorrent.com", 6881)); s.add_dht_router(std::pair<std::string, int>("router.utorrent.com", 6881));
sett.set_bool(settings_pack::enable_dht, true);
s.apply_settings(sett);
FILE* f = fopen(".dht", "rb"); FILE* f = fopen(".dht", "rb");
if (f != NULL) if (f != NULL)