From 385297ee4048175a165f1df5b9ce2a948e893c72 Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Sun, 10 Aug 2025 16:47:56 +0200 Subject: [PATCH] daemon/libnetwork/types: remove unused IsIPNetValid utility Signed-off-by: Sebastiaan van Stijn --- daemon/libnetwork/types/types.go | 6 ------ 1 file changed, 6 deletions(-) diff --git a/daemon/libnetwork/types/types.go b/daemon/libnetwork/types/types.go index c41d6784dd..12db5dd7be 100644 --- a/daemon/libnetwork/types/types.go +++ b/daemon/libnetwork/types/types.go @@ -251,12 +251,6 @@ func CompareIPNet(a, b *net.IPNet) bool { return a.IP.Equal(b.IP) && bytes.Equal(a.Mask, b.Mask) } -// IsIPNetValid returns true if the ipnet is a valid network/mask -// combination. Otherwise returns false. -func IsIPNetValid(nw *net.IPNet) bool { - return nw.String() != "0.0.0.0/0" -} - var v4inV6MaskPrefix = []byte{0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff} // compareIPMask checks if the passed ip and mask are semantically compatible.