]> The Tcpdump Group git mirrors - libpcap/commitdiff
Squelch a compiler warning.
authorGuy Harris <[email protected]>
Sat, 1 Sep 2018 01:17:35 +0000 (18:17 -0700)
committerGuy Harris <[email protected]>
Sat, 1 Sep 2018 01:17:35 +0000 (18:17 -0700)
bpf_filter.c

index af19158daf1a42c42c2d551a3fc7ba59a505f9ac..ebf118f42d829586a2df6ba28e96f42c7d6d990f 100644 (file)
@@ -44,6 +44,7 @@
 
 #include <pcap/pcap-inttypes.h>
 #include "pcap-types.h"
+#include "varattrs.h"
 #include "extract.h"
 
 #define EXTRACT_SHORT  EXTRACT_BE_U_2
@@ -83,9 +84,15 @@ enum {
  *
  * Thanks to Ani Sinha <[email protected]> for providing initial implementation
  */
+#if defined(SKF_AD_VLAN_TAG_PRESENT)
 u_int
 bpf_filter_with_aux_data(const struct bpf_insn *pc, const u_char *p,
     u_int wirelen, u_int buflen, const struct bpf_aux_data *aux_data)
+#else
+u_int
+bpf_filter_with_aux_data(const struct bpf_insn *pc, const u_char *p,
+    u_int wirelen, u_int buflen, const struct bpf_aux_data *aux_data _U_)
+#endif
 {
        register uint32_t A, X;
        register bpf_u_int32 k;
@@ -370,7 +377,6 @@ bpf_filter(const struct bpf_insn *pc, const u_char *p, u_int wirelen,
        return bpf_filter_with_aux_data(pc, p, wirelen, buflen, NULL);
 }
 
-
 /*
  * Return true if the 'fcode' is a valid filter program.
  * The constraints are that each jump be forward and to a valid