Module:IP: Difference between revisions
From the Croc Wiki, the Croc encyclopedia
Jump to navigationJump to search
Content added Content deleted
(fix bit calculation bug in RawIP:getHighestHost) |
(simplify RawIP:getPrefix) |
||
Line 168: | Line 168: | ||
bitLength = bitLength - 16 |
bitLength = bitLength - 16 |
||
else |
else |
||
result[i] = bit32. |
result[i] = bit32.replace(self[i], 0, 0, 16 - bitLength) |
||
bit32.arshift(0xffff8000, bitLength - 1)) |
|||
bitLength = 0 |
bitLength = 0 |
||
end |
end |