From ecc3d0c238d24d15d6d37d0d884b5e51382f456e Mon Sep 17 00:00:00 2001 From: "Franklin \"Snaipe\" Mathieu" Date: Fri, 4 Nov 2016 18:51:56 +0100 Subject: [PATCH] ws: Fixed field type not being resolved for int/uint sizes not divisible by 8 --- src/wssdl/wireshark.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wssdl/wireshark.lua b/src/wssdl/wireshark.lua index 3a83aa1..8892a39 100644 --- a/src/wssdl/wireshark.lua +++ b/src/wssdl/wireshark.lua @@ -93,7 +93,7 @@ ws.make_fields = function (fields, pkt, prefix) if type(len) ~= 'number' then error('wssdl: Cannot compute size of primitive ' .. utils.quote(field._name) .. ' field.') end - tname = tname .. tostring(len) + tname = tname .. tostring(len > 32 and 64 or math.ceil(len / 8) * 8) end ftype = ftypes[tname]