aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-ppi.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-ppi.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-ppi.c')
-rw-r--r--epan/dissectors/packet-ppi.c13
1 files changed, 2 insertions, 11 deletions
diff --git a/epan/dissectors/packet-ppi.c b/epan/dissectors/packet-ppi.c
index 78ca36c363..9275ccbcb0 100644
--- a/epan/dissectors/packet-ppi.c
+++ b/epan/dissectors/packet-ppi.c
@@ -60,8 +60,6 @@
#include <wiretap/pcap-encap.h>
#include "packet-frame.h"
-#include "packet-eth.h"
-#include "packet-ieee80211.h"
/*
* Per-Packet Information (PPI) header.
@@ -398,15 +396,7 @@ capture_ppi(const guchar *pd, int offset _U_, int len, packet_counts *ld, const
dlt = pletoh32(pd+4);
- /* XXX - We should probably combine this with capture_info.c:capture_info_packet() */
- switch(dlt) {
- case 1: /* DLT_EN10MB */
- return capture_eth(pd, ppi_len, len, ld, pseudo_header);
- case 105: /* DLT_DLT_IEEE802_11 */
- return capture_ieee80211(pd, ppi_len, len, ld, pseudo_header);
- }
-
- return FALSE;
+ return try_capture_dissector("ppi", dlt, pd, ppi_len, len, ld, pseudo_header);
}
static void
@@ -1489,6 +1479,7 @@ proto_register_ppi(void)
expert_register_field_array(expert_ppi, ei, array_length(ei));
ppi_handle = register_dissector("ppi", dissect_ppi, proto_ppi);
+ register_capture_dissector_table("ppi", "PPI");
register_init_routine(ampdu_reassemble_init);
register_cleanup_routine(ampdu_reassemble_cleanup);