Revision history [back]

First, you don't need to add the dofile(DATA_DIR.."omci.lua") to init.lua.

The 2 Lua files were written long ago and BinDecHex.lua requires at least the following 2 tweaks to work now, which I've made and uploaded back to the https://wiki.wireshark.org/Contrib page.

Change line 53 from:

module(..., package.seeall);


To:

module("BinDecHex", package.seeall);


The module function is deprecated as of Lua 5.2, as mentioned in section 8 of the Lua 5.2 Reference Manual - Incompatibilities with the Previous Version.

And change line 135 from:

for i in string.gfind(s, ".") do


to:

for i in string.gmatch(s, ".") do


Function string.gfind was renamed string.gmatch, as mentioned in section 7.2 of the Lua 5.1 Reference Manual - [Changes in the Libraries].

Wireshark currently ships with Lua 5.2.4 (on Windows), so always use the Lua 5.2 Reference Manual when writing or dealing with Lua dissectors.

First, you don't need to add the dofile(DATA_DIR.."omci.lua") to init.lua.

The 2 Lua files were written long ago and BinDecHex.lua requires at least the following 2 tweaks to work now, which I've made and uploaded back to the https://wiki.wireshark.org/Contrib page.

Change line 53 from:

module(..., package.seeall);


To:

module("BinDecHex", package.seeall);


The module function is deprecated as of Lua 5.2, as mentioned in section 8 of the Lua 5.2 Reference Manual - Incompatibilities with the Previous Version.

And change line 135 from:

for i in string.gfind(s, ".") do


to:

for i in string.gmatch(s, ".") do


Function string.gfind was renamed string.gmatch, as mentioned in section 7.2 of the Lua 5.1 Reference Manual - [Changes in the Libraries].Changes in the Libraries.

Wireshark currently ships with Lua 5.2.4 (on Windows), so always use the Lua 5.2 Reference Manual when writing or dealing with Lua dissectors.