Wireshark-commits: [Wireshark-commits] master 21a61a8: Add Lua Struct.values() function, and preven
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=21a61a8cb1bad305a2653aa14d2cdb53472f9f20
Submitter: Anders Broman (a.broman58@xxxxxxxxx)
Changed: branch: master
Repository: wireshark
Commits:
21a61a8 by Hadriel Kaplan (hadrielk@xxxxxxxxx):
Add Lua Struct.values() function, and prevent coercion in all Struct functions
This adds a Struct.values() function to get the number of values
needed/returned with Struct.pack/unpack. It also changes the existing
Struct functions such that they don't coerce a non-string argument
into a string. (not preventing it confused a user on ask.wireshark.org)
Change-Id: I93d5846105e55b67680e1c276a7286535c77b039
Reviewed-on: https://code.wireshark.org/review/790
Reviewed-by: Hadriel Kaplan <hadrielk@xxxxxxxxx>
Reviewed-by: Anders Broman <a.broman58@xxxxxxxxx>
Actions performed:
from 9950510 Add missing modelines info
adds 21a61a8 Add Lua Struct.values() function, and prevent coercion in all Struct functions
Summary of changes:
epan/wslua/wslua.h | 2 +
epan/wslua/wslua_internals.c | 14 +++++++
epan/wslua/wslua_struct.c | 92 ++++++++++++++++++++++++++++++------------
test/lua/struct.lua | 19 +++++++++
4 files changed, 101 insertions(+), 26 deletions(-)