This is a static archive of our old Q&A Site. Please post any new questions and answers at ask.wireshark.org.

attempt to index global ‘bit32’ (a nil value)

0

Hi,

I am writing a dissector for wireshark, I used bit32.band operation in that. I tried to run the dissector, got an error "attempt to index global 'bit32' (a nil value).

I realized that my version has lua 5.1, which doesn't have bit32. Can someone please give me an alternative?

TIA, Abhilash

asked 06 Aug '14, 08:53

abhilash's gravatar image

abhilash
10224
accept rate: 0%


One Answer:

1

Wireshark has Mike Pall's BitOp library built-in, regardless of Lua engine version. I'm not sure why it's not documented in the API docs, but you can find info here.

answered 07 Aug '14, 07:33

Hadriel's gravatar image

Hadriel
2.7k2939
accept rate: 18%