From 9d031308aa2ccf9e2b1aa4642af95f7577de5fd4 Mon Sep 17 00:00:00 2001 From: niten Date: Fri, 3 Nov 2023 11:51:22 -0700 Subject: [PATCH] Need to compare ints --- lib/lib/ip.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/lib/ip.nix b/lib/lib/ip.nix index 33d477a..b9a282a 100644 --- a/lib/lib/ip.nix +++ b/lib/lib/ip.nix @@ -65,7 +65,8 @@ in rec { ip-int = ipv4ToInt ip; net-min = networkMinIp network; net-max = networkMaxIp network; - in (ip-int >= networkMinIp) && (ip-int <= networkMaxIp); + in (ip-int >= (ipv4ToInt networkMinIp)) + && (ip-int <= (ipv4ToInt networkMaxIp)); getNetworkMask = network: toInt (elemAt (splitString "/" network) 1);