summaryrefslogtreecommitdiff
path: root/epan/packet.h
diff options
context:
space:
mode:
authorStig Bjørlykke <stig@bjorlykke.org>2015-08-11 14:08:08 +0200
committerStig Bjørlykke <stig@bjorlykke.org>2015-08-11 12:09:07 +0000
commitecc4f756bdb6175cc0b3b11af2f90884db1c602c (patch)
tree99d8ca48a72752e1257d4b8b321f41d1767ee020 /epan/packet.h
parent70d06deb2e31bd605e672200a7755764febe94ae (diff)
downloadwireshark-ecc4f756bdb6175cc0b3b11af2f90884db1c602c.tar.gz
Added Reload Lua plugins.
This is initial support for reloading Lua plugins without restarting the application. Still todo: - Deregister FileHandlers - Support deregister ProtoField with existing abbrev (same_name_hfinfo) - Add a progress dialog when reloading many plugins - Search for memory leakages in wslua functions Change-Id: I48870d8741251705ca15ffe1068613fcb0cb18c1 Reviewed-on: https://code.wireshark.org/review/5028 Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
Diffstat (limited to 'epan/packet.h')
-rw-r--r--epan/packet.h19
1 files changed, 15 insertions, 4 deletions
diff --git a/epan/packet.h b/epan/packet.h
index b2dfe43986..cd81bc2ddb 100644
--- a/epan/packet.h
+++ b/epan/packet.h
@@ -213,6 +213,9 @@ WS_DLL_PUBLIC dissector_table_t register_dissector_table(const char *name,
WS_DLL_PUBLIC dissector_table_t register_custom_dissector_table(const char *name,
const char *ui_name, GHashFunc hash_func, GEqualFunc key_equal_func);
+/** Deregister the dissector table by table name. */
+WS_DLL_PUBLIC void deregister_dissector_table(const char *name);
+
/* Find a dissector table by table name. */
WS_DLL_PUBLIC dissector_table_t find_dissector_table(const char *name);
@@ -484,10 +487,13 @@ WS_DLL_PUBLIC void heur_dissector_delete(const char *name, heur_dissector_t diss
extern void heur_dissector_set_enabled(const char *name, heur_dissector_t dissector, const int proto, const gboolean enabled);
/** Register a dissector. */
-WS_DLL_PUBLIC dissector_handle_t register_dissector(const char *name, dissector_t dissector,
- const int proto);
-WS_DLL_PUBLIC dissector_handle_t new_register_dissector(const char *name, new_dissector_t dissector,
- const int proto);
+WS_DLL_PUBLIC dissector_handle_t register_dissector(const char *name, dissector_t dissector, const int proto);
+
+/** Register a new dissector. */
+WS_DLL_PUBLIC dissector_handle_t new_register_dissector(const char *name, new_dissector_t dissector, const int proto);
+
+/** Deregister a dissector. */
+WS_DLL_PUBLIC void deregister_dissector(const char *name);
/** Get the long name of the protocol for a dissector handle. */
extern const char *dissector_handle_get_long_name(const dissector_handle_t handle);
@@ -515,6 +521,9 @@ WS_DLL_PUBLIC dissector_handle_t new_create_dissector_handle(new_dissector_t dis
WS_DLL_PUBLIC dissector_handle_t new_create_dissector_handle_with_name(new_dissector_t dissector,
const int proto, const char* name);
+/** Destroy an anonymous handle for a dissector. */
+WS_DLL_PUBLIC void destroy_dissector_handle(dissector_handle_t handle);
+
/** Call a dissector through a handle and if no dissector was found
* pass it over to the "data" dissector instead.
*
@@ -699,6 +708,8 @@ WS_DLL_PUBLIC void dissector_dump_heur_decodes(void);
* dissector has been called.
*/
WS_DLL_PUBLIC void register_postdissector(dissector_handle_t);
+WS_DLL_PUBLIC void deregister_postdissector(dissector_handle_t handle);
+
extern gboolean have_postdissector(void);
extern void call_all_postdissectors(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree);