summaryrefslogtreecommitdiffhomepage
path: root/tunnel/src/main/java/com/wireguard/config
diff options
context:
space:
mode:
Diffstat (limited to 'tunnel/src/main/java/com/wireguard/config')
-rw-r--r--tunnel/src/main/java/com/wireguard/config/InetNetwork.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/tunnel/src/main/java/com/wireguard/config/InetNetwork.java b/tunnel/src/main/java/com/wireguard/config/InetNetwork.java
index 0c993fc8..7fd12577 100644
--- a/tunnel/src/main/java/com/wireguard/config/InetNetwork.java
+++ b/tunnel/src/main/java/com/wireguard/config/InetNetwork.java
@@ -47,7 +47,7 @@ public final class InetNetwork {
final int maxMask = (address instanceof Inet4Address) ? 32 : 128;
if (rawMask > maxMask)
throw new ParseException(InetNetwork.class, maskString, "Invalid network mask");
- final int mask = rawMask >= 0 && rawMask <= maxMask ? rawMask : maxMask;
+ final int mask = rawMask >= 0 ? rawMask : maxMask;
return new InetNetwork(address, mask);
}