forked from PretendoNetwork/Inkay
fix: getaddrinfo(NULL) is valid apparently
This commit is contained in:
parent
10688b5ac2
commit
e1558493f2
1 changed files with 1 additions and 0 deletions
|
|
@ -34,6 +34,7 @@ constexpr std::pair<const char *, const char *> dns_replacements[] = {
|
||||||
|
|
||||||
static const char * replace_dns_name(const char *dns_name) {
|
static const char * replace_dns_name(const char *dns_name) {
|
||||||
if (!Config::connect_to_network) return dns_name;
|
if (!Config::connect_to_network) return dns_name;
|
||||||
|
if (!dns_name) return dns_name;
|
||||||
|
|
||||||
for (auto [original, replacement] : dns_replacements) {
|
for (auto [original, replacement] : dns_replacements) {
|
||||||
if (strcmp(original, dns_name) == 0)
|
if (strcmp(original, dns_name) == 0)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue