Fix initialization of inaddr_any
This commit is contained in:
parent
d960a335f8
commit
839c4e7966
@ -614,7 +614,8 @@ bool AppInit2(int argc, char* argv[])
|
|||||||
fBound |= Bind(CService(strBind, GetDefaultPort(), false));
|
fBound |= Bind(CService(strBind, GetDefaultPort(), false));
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
struct in_addr inaddr_any = {s_addr: INADDR_ANY};
|
struct in_addr inaddr_any;
|
||||||
|
inaddr_any.s_addr = INADDR_ANY;
|
||||||
fBound |= Bind(CService(inaddr_any, GetDefaultPort()));
|
fBound |= Bind(CService(inaddr_any, GetDefaultPort()));
|
||||||
#ifdef USE_IPV6
|
#ifdef USE_IPV6
|
||||||
fBound |= Bind(CService(in6addr_any, GetDefaultPort()));
|
fBound |= Bind(CService(in6addr_any, GetDefaultPort()));
|
||||||
|
Loading…
Reference in New Issue
Block a user