aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2017-12-13 19:16:28 -0800
committerGuy Harris <guy@alum.mit.edu>2017-12-14 03:17:02 +0000
commit6af7b9a63ad8c7ce7b57e0d8adcb5e61d70a2123 (patch)
tree91d7b59046c875da83cfe1729c3b311ceb49a4ec
parent7539469d79d80944ab2daa389aade7991302835d (diff)
Register the UDS dissector by name.
See https://ask.wireshark.org/question/891/use-uds-dissector-inside-doip-dissector/ Change-Id: I608b4ffb90e65fd31e9f3e421f4c473f4e66bebd Reviewed-on: https://code.wireshark.org/review/24818 Reviewed-by: Guy Harris <guy@alum.mit.edu>
-rw-r--r--epan/dissectors/packet-uds.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/epan/dissectors/packet-uds.c b/epan/dissectors/packet-uds.c
index 2da479e..19c4fae 100644
--- a/epan/dissectors/packet-uds.c
+++ b/epan/dissectors/packet-uds.c
@@ -380,6 +380,8 @@ static gint ett_uds_cdtcs = -1;
static int proto_uds = -1;
+static dissector_handle_t uds_handle;
+
static
guint8 masked_guint8_value(const guint8 value, const guint8 mask)
{
@@ -1076,14 +1078,13 @@ proto_register_uds(void)
proto_register_field_array(proto_uds, hf, array_length(hf));
proto_register_subtree_array(ett, array_length(ett));
+
+ uds_handle = register_dissector("uds", dissect_uds, proto_uds);
}
void
proto_reg_handoff_uds(void)
{
- static dissector_handle_t uds_handle;
-
- uds_handle = create_dissector_handle(dissect_uds, proto_uds);
dissector_add_for_decode_as("iso15765.subdissector", uds_handle);
}