aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-netrom.c
diff options
context:
space:
mode:
authorMichael Mann <mmann78@netscape.net>2015-12-14 08:48:59 -0500
committerMichael Mann <mmann78@netscape.net>2015-12-14 22:35:15 +0000
commitd835b271679c5e5eae7146b96ae1a65cbd5c16b4 (patch)
tree68bd42732c1b6ee509f9ae69bdaf8a6513c16f1d /epan/dissectors/packet-netrom.c
parent54413c8594ab6fb8518ad9347f21d58038fceed9 (diff)
Create some more capture dissector tables.
These were created from capture dissector functions that had switch statements determine "next" protocol/dissector. The registration decreases the need for function declarations in header files. Added new capture dissection tables for IP, IPv6, TCP and UDP as that seems like the next logical place to expand Change-Id: I1ec0cd54eecda4f400669ee5b026bf6e2b46545a Reviewed-on: https://code.wireshark.org/review/12634 Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'epan/dissectors/packet-netrom.c')
-rw-r--r--epan/dissectors/packet-netrom.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/epan/dissectors/packet-netrom.c b/epan/dissectors/packet-netrom.c
index 6c34abac05..d15d27ee99 100644
--- a/epan/dissectors/packet-netrom.c
+++ b/epan/dissectors/packet-netrom.c
@@ -45,10 +45,9 @@
#include <epan/packet.h>
#include <epan/to_str.h>
+#include <epan/capture_dissectors.h>
#include <epan/ax25_pids.h>
-#include "packet-netrom.h"
-
void proto_register_netrom(void);
void proto_reg_handoff_netrom(void);
@@ -488,7 +487,7 @@ dissect_netrom(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _
return tvb_captured_length(tvb);
}
-gboolean
+static gboolean
capture_netrom( const guchar *pd _U_, int offset, int len, packet_counts *ld _U_, const union wtap_pseudo_header *pseudo_header _U_)
{
if ( ! BYTES_ARE_IN_FRAME( offset, len, NETROM_MIN_SIZE ) )
@@ -625,6 +624,7 @@ void
proto_reg_handoff_netrom(void)
{
dissector_add_uint( "ax25.pid", AX25_P_NETROM, create_dissector_handle( dissect_netrom, proto_netrom ) );
+ register_capture_dissector("ax25.pid", AX25_P_NETROM, capture_netrom, proto_netrom);
ip_handle = find_dissector( "ip" );
data_handle = find_dissector( "data" );