1 /* register-int.h 2 * Definitions for protocol registration 3 * 4 * Wireshark - Network traffic analyzer 5 * By Gerald Combs <gerald@wireshark.org> 6 * Copyright 1998 Gerald Combs 7 * 8 * SPDX-License-Identifier: GPL-2.0-or-later 9 */ 10 11 #ifndef __REGISTER_INT_H__ 12 #define __REGISTER_INT_H__ 13 14 #include "register.h" 15 16 #ifdef __cplusplus 17 extern "C" { 18 #endif /* __cplusplus */ 19 20 /** Call each dissector's protocol registration routine. 21 * 22 * Each routine is called in alphabetical order from a worker thread. 23 * Registration routines might call any number of routines which are not 24 * thread safe, such as wmem_alloc. Callbacks should handle themselves 25 * accordingly. 26 * 27 * @param cb Callback routine which is called for each protocol. 28 * Messages have the format "proto_register_XXX". 29 * @param client_data Data pointer for the callback. 30 */ 31 void register_all_protocols(register_cb cb, gpointer client_data); 32 33 /** Call each dissector's protocol handoff routine. 34 * 35 * Each routine is called from a worker thread. Registration routines 36 * might call any number of routines which are not thread safe, such as 37 * wmem_alloc. Callbacks should handle themselves accordingly. 38 * 39 * @param cb Callback routine which is called for each protocol. 40 * Messages have the format "proto_reg_handoff_XXX". 41 * @param client_data Data pointer for the callback. 42 */ 43 void register_all_protocol_handoffs(register_cb cb, gpointer client_data); 44 45 gulong register_count(void); 46 47 #ifdef __cplusplus 48 } 49 #endif /* __cplusplus */ 50 51 #endif /* __REGISTER_INT_H__ */ 52 53 /* 54 * Editor modelines - https://www.wireshark.org/tools/modelines.html 55 * 56 * Local Variables: 57 * c-basic-offset: 4 58 * tab-width: 8 59 * indent-tabs-mode: nil 60 * End: 61 * 62 * vi: set shiftwidth=4 tabstop=8 expandtab: 63 * :indentSize=4:tabSize=8:noTabs=true: 64 */ 65