mirror of
https://github.com/libretro/Lakka-LibreELEC.git
synced 2025-04-02 10:41:46 -04:00
update 1.0pre4 (2014-01-19) to 77901c8c (2018-10-03) changelog: https://code.blinkace.com/pdw/iftop/commits/master updated PKG_URL and PKG_SITE
54 lines
1.7 KiB
Diff
54 lines
1.7 KiB
Diff
diff -Nuar iftop-77901c8c/iftop-dump.c iftop-pcap-1-10/iftop-dump.c
|
|
--- iftop-77901c8c/iftop-dump.c 2018-10-03 17:02:36.000000000 +0000
|
|
+++ iftop-pcap-1-10/iftop-dump.c 2021-01-17 23:40:39.896124155 +0000
|
|
@@ -64,7 +64,7 @@
|
|
pthread_mutex_t tick_mutex;
|
|
|
|
pcap_t* pd; /* pcap descriptor */
|
|
-struct bpf_program pcap_filter;
|
|
+struct bpf_program my_pcap_filter;
|
|
pcap_handler packet_handler;
|
|
|
|
FILE*fout = NULL;
|
|
@@ -375,12 +375,12 @@
|
|
sprintf(x, "(%s) and ip", filter);
|
|
} else
|
|
x = xstrdup("ip");
|
|
- if (pcap_compile(pd, &pcap_filter, x, 1, 0) == -1) {
|
|
+ if (pcap_compile(pd, &my_pcap_filter, x, 1, 0) == -1) {
|
|
xfree(x);
|
|
return pcap_geterr(pd);
|
|
}
|
|
xfree(x);
|
|
- if (pcap_setfilter(pd, &pcap_filter) == -1)
|
|
+ if (pcap_setfilter(pd, &my_pcap_filter) == -1)
|
|
return pcap_geterr(pd);
|
|
else
|
|
return NULL;
|
|
diff -Nuar iftop-77901c8c/iftop.c iftop-pcap-1-10/iftop.c
|
|
--- iftop-77901c8c/iftop.c 2018-10-03 17:02:36.000000000 +0000
|
|
+++ iftop-pcap-1-10/iftop.c 2021-01-17 23:40:54.116240467 +0000
|
|
@@ -74,7 +74,7 @@
|
|
pthread_mutex_t tick_mutex;
|
|
|
|
pcap_t* pd; /* pcap descriptor */
|
|
-struct bpf_program pcap_filter;
|
|
+struct bpf_program my_pcap_filter;
|
|
pcap_handler packet_handler;
|
|
|
|
sig_atomic_t foad;
|
|
@@ -679,12 +679,12 @@
|
|
sprintf(x, "(%s) and (ip or ip6)", filter);
|
|
} else
|
|
x = xstrdup("ip or ip6");
|
|
- if (pcap_compile(pd, &pcap_filter, x, 1, 0) == -1) {
|
|
+ if (pcap_compile(pd, &my_pcap_filter, x, 1, 0) == -1) {
|
|
xfree(x);
|
|
return pcap_geterr(pd);
|
|
}
|
|
xfree(x);
|
|
- if (pcap_setfilter(pd, &pcap_filter) == -1)
|
|
+ if (pcap_setfilter(pd, &my_pcap_filter) == -1)
|
|
return pcap_geterr(pd);
|
|
else
|
|
return NULL;
|