libpcap/ieee80215-arphrd.patch

24 lines
671 B
Diff
Raw Normal View History

2019-09-30 10:57:32 -04:00
diff --git a/pcap-linux.c b/pcap-linux.c
index 58782ae..b7a813d 100644
--- a/pcap-linux.c
+++ b/pcap-linux.c
@@ -3499,6 +3499,17 @@ static void map_arphrd_to_dlt(pcap_t *handle, int sock_fd, int arptype,
* XXX - this is handled in activate_new(). */
/* handlep->cooked = 1; */
break;
+#ifndef ARPHRD_IEEE80215
+#define ARPHRD_IEEE80215 805
+#endif
+#ifndef ARPHRD_IEEE80215_PHY
+#define ARPHRD_IEEE80215_PHY 806
+#endif
+
+ case ARPHRD_IEEE80215:
+ case ARPHRD_IEEE80215_PHY:
+ handle->linktype = DLT_IEEE802_15_4;
+ break;
/* ARPHRD_LAPD is unofficial and randomly allocated, if reallocation
* is needed, please report it to <daniele@orlandi.com> */
2019-12-25 15:54:18 +08:00