diff options
author | Pau Espin Pedrol <pespin@sysmocom.de> | 2017-04-20 12:44:04 +0200 |
---|---|---|
committer | Pau Espin Pedrol <pespin@sysmocom.de> | 2017-08-08 20:39:16 +0200 |
commit | 6032a35be84c87607e295e46f1e37d3dd4e5f1b1 (patch) | |
tree | 1f6adc9e2508132727c9ff839fd7c4ce4f08b69e /tests/osmo-pcap-test/l4_udp.c | |
parent | 76c0acb149a03e6d7945e0ee4f4c6355381b7391 (diff) |
tests: osmo-pcap: Allow different l2 pkts
Before this patch, ETH was assumed and other types were not supported.
This patch also adds Linux cooked packet support for L2.
Change-Id: Ie62fa0a8e45e1e141edb64b116dad185ad9c7a5f
Diffstat (limited to 'tests/osmo-pcap-test/l4_udp.c')
-rw-r--r-- | tests/osmo-pcap-test/l4_udp.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/osmo-pcap-test/l4_udp.c b/tests/osmo-pcap-test/l4_udp.c index 9ffa77b..1733908 100644 --- a/tests/osmo-pcap-test/l4_udp.c +++ b/tests/osmo-pcap-test/l4_udp.c @@ -13,12 +13,12 @@ #include "proto.h" -static int l4_udp_pkt_hdr_len(const uint8_t *pkt) +static unsigned int l4_udp_pkt_hdr_len(const uint8_t *pkt) { return sizeof(struct udphdr); } -static int l4_udp_pkt_no_data(const uint8_t *pkt) +static unsigned int l4_udp_pkt_no_data(const uint8_t *pkt) { /* UDP has no control packets. */ return 0; |