path: root/ui/decode_as_utils.h
diff options
authorMichael Mann <mmann78@netscape.net>2016-10-07 16:25:01 -0400
committerMichael Mann <mmann78@netscape.net>2016-10-08 02:44:53 +0000
commit268841f3e00b7cf0f16c81dd2b3b952172130b8b (patch)
tree359e01cf5eba83308760531888713fe0ff0bc10b /ui/decode_as_utils.h
parent11d3224142c0531879fb8e415daf9639a4eace66 (diff)
Combine Decode As and port preferences for tcp.port dissector table.
This patch introduces new APIs to allow dissectors to have a preference for a (TCP) port, but the underlying data is actually part of Decode As functionality. For now the APIs are intentionally separate from the regular APIs that register a dissector within a dissector table. It may be possible to eventually combine the two so that all dissectors that register with a dissector table have an opportunity to "automatically" have a preference to adjust the "table value" through the preferences dialog. The tcp.port dissector table was used as the guinea pig. This will eventually be expanded to other dissector tables as well (most notably UDP ports). Some dissectors that "shared" a TCP/UDP port preference were also converted. It also removed the need for some preference callback functions (mostly when the callback function was the proto_reg_handoff function) so there is cleanup around that. Dissectors that has a port preference whose default was 0 were switched to using the dissector_add_for_decode_as_with_preference API rather than dissector_add_uint_with_preference Also added comments for TCP ports used that aren't IANA registered. Change-Id: I99604f95d426ad345f4b494598d94178b886eb67 Reviewed-on: https://code.wireshark.org/review/17724 Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'ui/decode_as_utils.h')
1 files changed, 0 insertions, 38 deletions
diff --git a/ui/decode_as_utils.h b/ui/decode_as_utils.h
index 50008182d4..7ae3b7cd08 100644
--- a/ui/decode_as_utils.h
+++ b/ui/decode_as_utils.h
@@ -35,44 +35,6 @@
extern "C" {
#endif /* __cplusplus */
-/** Reset the "decode as" entries and reload ones of the current profile.
- */
-void load_decode_as_entries(void);
-/** Write out the "decode as" entries of the current profile.
- */
-int save_decode_as_entries(gchar** err);
-/** This routine creates one entry in the list of protocol dissector
- * that need to be reset. It is called by the g_hash_table_foreach
- * routine once for each changed entry in a dissector table.
- * Unfortunately it cannot delete the entry immediately as this screws
- * up the foreach function, so it builds a list of dissectors to be
- * reset once the foreach routine finishes.
- *
- * @param table_name The table name in which this dissector is found.
- *
- * @param key A pointer to the key for this entry in the dissector
- * hash table. This is generally the numeric selector of the
- * protocol, i.e. the ethernet type code, IP port number, TCP port
- * number, etc.
- *
- * @param selector_type The type of the selector in that dissector table
- *
- * @param value A pointer to the value for this entry in the dissector
- * hash table. This is an opaque pointer that can only be handed back
- * to routine in the file packet.c - but it's unused.
- *
- * @param user_data Unused.
- */
-void decode_build_reset_list (const gchar *table_name, ftenum_t selector_type,
- gpointer key, gpointer value _U_,
- gpointer user_data _U_);
-/** Clear all "decode as" settings.
- */
-void decode_clear_all(void);
* This is the template for the decode as option; it is shared between the
* various functions that output the usage for this parameter.