Wireshark-bugs: [Wireshark-bugs] [Bug 3513] Lua dissector field registration broken
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=3513
Andrew Baxter <abaxter@xxxxxxxxxxxxxxxxx> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |abaxter@xxxxxxxxxxxxxxxxx
--- Comment #4 from Andrew Baxter <abaxter@xxxxxxxxxxxxxxxxx> 2009-06-10 10:50:57 PDT ---
Thank you very much for your replies. I for some reason didn't receive any
notifications, so I thought that nothing was happening here.
What I meant, regarding Lua usability, was that the Lua taps are most easily
(only?) usable with Lua dissectors, and I can't get any of my Lua registered
fields out, which are necessary for my tap.
In ProtoField_new, I can't see that proto_register_field_init is called,
directly or indirectly. It seems only Lua functions are called. I thought
pushProtoField might, but the macro you pointed out to me is called with:
; WSLUA_CLASS_DEFINE(ProtoField,FAIL_ON_NULL("null ProtoField"),NOP);
This would mean, I think, that pushProtoField is defined as:
; ProtoField* push##C(lua_State* L, ProtoField v) { \
; ProtoField* p; \
; luaL_checkstack(L,2,"Unable to grow stack\n"); \
; p = lua_newuserdata(L,sizeof(ProtoField)); *p = v; \
; luaL_getmetatable(L, ProtoField); lua_setmetatable(L, -2); \
; NOP; \
; return p; \
; }
Does this mean that pushProtoField just pushes the userdata to the stack and
doesn't register it? The field must be registered /somewhere/, because I can
create filters with it, but I still can't seem to use the filter in my tap.
Do you have any other tips for pinpointing the registration?
Thanks again for all your help.
--
Configure bugmail: https://bugs.wireshark.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.