(face37755) Fixed clients timing out when trying to connect to a server that has banned someone. Closes #1568
This commit is contained in:
@@ -35,6 +35,7 @@ namespace Barotrauma.Networking
|
|||||||
|
|
||||||
public bool CompareTo(string ipCompare)
|
public bool CompareTo(string ipCompare)
|
||||||
{
|
{
|
||||||
|
if (string.IsNullOrEmpty(IP)) { return false; }
|
||||||
if (!IsRangeBan)
|
if (!IsRangeBan)
|
||||||
{
|
{
|
||||||
return ipCompare == IP;
|
return ipCompare == IP;
|
||||||
@@ -49,6 +50,7 @@ namespace Barotrauma.Networking
|
|||||||
|
|
||||||
public bool CompareTo(IPAddress ipCompare)
|
public bool CompareTo(IPAddress ipCompare)
|
||||||
{
|
{
|
||||||
|
if (string.IsNullOrEmpty(IP)) { return false; }
|
||||||
if (ipCompare.IsIPv4MappedToIPv6 && CompareTo(ipCompare.MapToIPv4().ToString()))
|
if (ipCompare.IsIPv4MappedToIPv6 && CompareTo(ipCompare.MapToIPv4().ToString()))
|
||||||
{
|
{
|
||||||
return true;
|
return true;
|
||||||
|
|||||||
Reference in New Issue
Block a user