# HG changeset patch # User Matthew Wild # Date 1322673616 0 # Node ID cbc3224ed3c2e6a0b4637de27aa7581765c10753 # Parent bbede0141f7ed97b4c84fb69a3efabefcf9476d7 util.ip: Fix in IP range calculation for 172.16.0.0/12 diff -r bbede0141f7e -r cbc3224ed3c2 util/ip.lua --- a/util/ip.lua Mon Nov 28 14:30:12 2011 +0000 +++ b/util/ip.lua Wed Nov 30 17:20:16 2011 +0000 @@ -65,7 +65,7 @@ elseif fields[1] == 169 and fields[2] == 254 then return 0x2; -- Site-local unicast: - elseif (fields[1] == 10) or (fields[1] == 192 and fields[2] == 168) or (fields[1] == 172 and fields[2] > 16) then + elseif (fields[1] == 10) or (fields[1] == 192 and fields[2] == 168) or (fields[1] == 172 and (fields[2] >= 16 and fields[2] < 32) then return 0x5; -- Global unicast: else