diff --git a/src/seeder/main.cpp b/src/seeder/main.cpp --- a/src/seeder/main.cpp +++ b/src/seeder/main.cpp @@ -18,6 +18,19 @@ const std::function G_TRANSLATION_FUN = nullptr; +static const int THREADS_DEFAULT = 96; +static const int PORT_DEFAULT = 53; +static const int DNSTHREADS_DEFAULT = 4; +static const bool TESTNET_DEFAULT = false; +static const bool WIPE_BAN_DEFAULT = false; +static const bool WIPE_IGNORE_DEFAULT = false; +static const char *MBOX_DEFAULT = nullptr; +static const char *NS_DEFAULT = nullptr; +static const char *HOST_DEFAULT = nullptr; +static const char *TOR_DEFAULT = nullptr; +static const char *IPV4_PROXY_DEFAULT = nullptr; +static const char *IPV6_PROXY_DEFAULT = nullptr; + class CDnsSeedOpts { public: int nThreads; @@ -35,10 +48,12 @@ std::set filter_whitelist; CDnsSeedOpts() - : nThreads(96), nPort(53), nDnsThreads(4), fUseTestNet(false), - fWipeBan(false), fWipeIgnore(false), mbox(nullptr), ns(nullptr), - host(nullptr), tor(nullptr), ipv4_proxy(nullptr), - ipv6_proxy(nullptr) {} + : nThreads(THREADS_DEFAULT), nPort(PORT_DEFAULT), + nDnsThreads(DNSTHREADS_DEFAULT), fUseTestNet(TESTNET_DEFAULT), + fWipeBan(WIPE_BAN_DEFAULT), fWipeIgnore(WIPE_IGNORE_DEFAULT), + mbox(MBOX_DEFAULT), ns(NS_DEFAULT), host(HOST_DEFAULT), + tor(TOR_DEFAULT), ipv4_proxy(IPV4_PROXY_DEFAULT), + ipv6_proxy(IPV6_PROXY_DEFAULT) {} void ParseCommandLine(int argc, char **argv) { static const char *help =