mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-08-26 07:59:09 +00:00
(svn r15954) -Fix: comparing addresses kinda fails (sometimes) causing duplicates in the game list
This commit is contained in:
@@ -175,7 +175,7 @@ public:
|
|||||||
{
|
{
|
||||||
int r = this->GetAddressLength() - address.GetAddressLength();
|
int r = this->GetAddressLength() - address.GetAddressLength();
|
||||||
if (r == 0) r = this->address.ss_family - address.address.ss_family;
|
if (r == 0) r = this->address.ss_family - address.address.ss_family;
|
||||||
if (r == 0) r = memcmp(&this->address, &address.address, this->address_length) == 0;
|
if (r == 0) r = memcmp(&this->address, &address.address, this->address_length);
|
||||||
if (r == 0) r = this->GetPort() - address.GetPort();
|
if (r == 0) r = this->GetPort() - address.GetPort();
|
||||||
return r;
|
return r;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user