mirror of
https://github.com/wownero/p2pool-wow.git
synced 2026-10-26 10:38:43 +01:00
Added --no-dns command line parameter
This commit is contained in:
@@ -353,8 +353,15 @@ static thread_local bool main_thread = false;
|
||||
void set_main_thread() { main_thread = true; }
|
||||
bool is_main_thread() { return main_thread; }
|
||||
|
||||
bool disable_resolve_host = false;
|
||||
|
||||
bool resolve_host(std::string& host, bool& is_v6)
|
||||
{
|
||||
if (disable_resolve_host) {
|
||||
LOGERR(1, "resolve_host was called with DNS disabled for host " << host);
|
||||
return false;
|
||||
}
|
||||
|
||||
addrinfo hints{};
|
||||
hints.ai_family = AF_UNSPEC;
|
||||
hints.ai_socktype = SOCK_STREAM;
|
||||
|
||||
Reference in New Issue
Block a user