mirror of https://github.com/PCSX2/pcsx2.git
DEV9: Skip over invalid gateways
This commit is contained in:
parent
ee3abe745c
commit
abeb1ca49d
|
@ -384,7 +384,8 @@ std::vector<IP_Address> AdapterUtils::GetGateways(const Adapter* adapter)
|
|||
if (ReadAddressFamily(address->Address.lpSockaddr) == AF_INET)
|
||||
{
|
||||
const sockaddr_in* sockaddr = reinterpret_cast<sockaddr_in*>(address->Address.lpSockaddr);
|
||||
collection.push_back(std::bit_cast<IP_Address>(sockaddr->sin_addr));
|
||||
if (sockaddr->sin_addr.S_un.S_addr != 0)
|
||||
collection.push_back(std::bit_cast<IP_Address>(sockaddr->sin_addr));
|
||||
}
|
||||
address = address->Next;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue