* luci/libs: fixed big endian in Hex() constructor
authorJo-Philipp Wich <jow@openwrt.org>
Fri, 8 Aug 2008 01:04:52 +0000 (01:04 +0000)
committerJo-Philipp Wich <jow@openwrt.org>
Fri, 8 Aug 2008 01:04:52 +0000 (01:04 +0000)
libs/core/luasrc/ip.lua

index 15730db..ad32e27 100644 (file)
@@ -211,6 +211,8 @@ function Hex( hex, prefix, family, swap )
 
        if swap and LITTLE_ENDIAN then
                for i = #hex, 1, -2 do tmp = tmp .. hex:sub( i - 1, i ) end
+       else
+               tmp = tmp .. hex
        end
 
        hex = tmp