diff --git a/Lidgren.Network/NetReservedAddress.cs b/Lidgren.Network/NetReservedAddress.cs index ea69315..fba91c5 100644 --- a/Lidgren.Network/NetReservedAddress.cs +++ b/Lidgren.Network/NetReservedAddress.cs @@ -45,7 +45,7 @@ public static bool IsAddressReserved(IPAddress address) foreach (var (reservedIp, maskBits) in ReservedRanges) { - var mask = uint.MaxValue << maskBits; + var mask = uint.MaxValue << (32 - maskBits); if ((ipBits & mask) == (reservedIp & mask)) return true; }