From a2216e14521763e702f69a9bfd046aa15a5b3f52 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Asbj=C3=B8rn=20Sloth=20T=C3=B8nnesen?= Date: Mon, 6 Mar 2017 10:54:38 +0000 Subject: luacheck: clean up MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Asbjørn Sloth Tønnesen --- lua/inet/init.lua | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'lua') diff --git a/lua/inet/init.lua b/lua/inet/init.lua index fcdabe9..99d1195 100644 --- a/lua/inet/init.lua +++ b/lua/inet/init.lua @@ -273,8 +273,7 @@ end function inet6:is_balanced() local pcs = self.pcs - local i = 8 - for i=i,8 do + for i=1,8 do local piece = pcs[i] if piece < 0 or piece > 0xffff then return false @@ -453,7 +452,7 @@ function inet6:flip() local flipbit = lshift(1, bitno) local r = self:clone() local val = r.pcs[block] - r.pcs[block] = bxor(r.pcs[block], flipbit) + r.pcs[block] = bxor(val, flipbit) --print(mask, block, maskbits, bitno, flipbit, self, r:balance()) return r end -- cgit v1.2.1