aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-s5066dts.c
diff options
context:
space:
mode:
authorJaap Keuter <jaap.keuter@xs4all.nl>2018-11-30 20:26:29 +0100
committerAnders Broman <a.broman58@gmail.com>2018-12-01 15:52:37 +0000
commit71268f8bd1458048e2d75f5a3b8bc94feb3b7d0c (patch)
tree238a56ead11eff27ac01a9ec76dc03e4d36840e9 /epan/dissectors/packet-s5066dts.c
parentc66fbf481fb3e4b39a36744230239f5eb953dd4e (diff)
Apply port preferences during dissector handoff registration
Handling of preferences is often done in the dissector handoff registration. Therefore this function is often registered as callback while registering preference handling for the module. In this way the preferences are processed both when registering the dissector and when changes happen. Some dissectors opt to register a seperate callback function to be called when preferences change. Now these have to be called from the dissector handoff function explicitly, in order to have the preferences processed during dissector registration. This becomes explicitly apparent when the port registration comes into play. With the migration to using dissector registration on ports with preference this port (range) is often retrieved from the preferences to match against the ports in a packet to determine an incoming or outgoing packet of a server. In case the callback function is not called from the dissector registration this determination fails, until the preferences are applied/changed, causing the preference handling callback to be called. This change add the calling of the callback during dissector registration, fixing some dissector port registrations in the process. Change-Id: Ieaea7f63f8f9062c56582a042a3a5a862e286406 Signed-off-by: Jaap Keuter <jaap.keuter@xs4all.nl> Reviewed-on: https://code.wireshark.org/review/30848 Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'epan/dissectors/packet-s5066dts.c')
-rw-r--r--epan/dissectors/packet-s5066dts.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/epan/dissectors/packet-s5066dts.c b/epan/dissectors/packet-s5066dts.c
index 33e933f19a..607abe9baf 100644
--- a/epan/dissectors/packet-s5066dts.c
+++ b/epan/dissectors/packet-s5066dts.c
@@ -1347,6 +1347,7 @@ void proto_reg_handoff_s5066dts(void)
s5066dts_over_tcp_handle = create_dissector_handle(dissect_s5066dts_tcp, proto_s5066dts);
dissector_add_for_decode_as_with_preference("tcp.port", s5066dts_over_tcp_handle);
+ apply_s5066dts_prefs();
}
/*