[MERGED] libosmo-netif[master]: tests: osmo-pcap-test: Fix pcap includes not found in old ve...

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Harald Welte gerrit-no-reply at lists.osmocom.org
Thu Apr 12 19:33:37 UTC 2018


Harald Welte has submitted this change and it was merged.

Change subject: tests: osmo-pcap-test: Fix pcap includes not found in old versions
......................................................................


tests: osmo-pcap-test: Fix pcap includes not found in old versions

pcap/dlt.h only exists on newer versions of libpcap. On older versions,
same defines are available in pcap/bpf.h, which in newer versions
include pcap/dlt.h, so we are always fine include pcap/bpf.h.
As a side note, there's a lots of comments in pcap/dlt.h stating that
those symbols used to reside in pcap/bpf.h but were moved there at some
point.

Change-Id: I824671a415eb3f35f480c934b9780ff13510011a
---
M tests/osmo-pcap-test/l2_eth.c
M tests/osmo-pcap-test/l2_sll.c
2 files changed, 2 insertions(+), 2 deletions(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/tests/osmo-pcap-test/l2_eth.c b/tests/osmo-pcap-test/l2_eth.c
index 3171fd7..34f003a 100644
--- a/tests/osmo-pcap-test/l2_eth.c
+++ b/tests/osmo-pcap-test/l2_eth.c
@@ -12,7 +12,7 @@
 #include <arpa/inet.h>
 #include <netinet/ip.h>
 #include <linux/if_ether.h>
-#include <pcap/dlt.h>
+#include <pcap/bpf.h>
 
 #include "proto.h"
 
diff --git a/tests/osmo-pcap-test/l2_sll.c b/tests/osmo-pcap-test/l2_sll.c
index 5a600ff..0f44e61 100644
--- a/tests/osmo-pcap-test/l2_sll.c
+++ b/tests/osmo-pcap-test/l2_sll.c
@@ -12,7 +12,7 @@
 #include <arpa/inet.h>
 #include <linux/if_ether.h>
 #include <pcap/sll.h>
-#include <pcap/dlt.h>
+#include <pcap/bpf.h>
 
 #include "proto.h"
 

-- 
To view, visit https://gerrit.osmocom.org/7785
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I824671a415eb3f35f480c934b9780ff13510011a
Gerrit-PatchSet: 1
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Owner: Pau Espin Pedrol <pespin at sysmocom.de>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder



More information about the gerrit-log mailing list