From 64b88abf981e44827de46bb09d5dd510b841f9f8 Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Wed, 25 Mar 2009 08:48:57 -0700 Subject: [PATCH] Move "union thdr" to pcap-int.h, as we use it in pcap-int.h. --- pcap-int.h | 8 ++++++++ pcap-linux.c | 6 ------ 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/pcap-int.h b/pcap-int.h index d5d310b..ab04d61 100644 --- a/pcap-int.h +++ b/pcap-int.h @@ -109,6 +109,14 @@ struct pcap_sf { u_char *base; }; +#ifdef linux +union thdr { + struct tpacket_hdr *h1; + struct tpacket2_hdr *h2; + void *raw; +}; +#endif + /* * Used when doing a live capture. */ diff --git a/pcap-linux.c b/pcap-linux.c index f35d459..b9809b0 100644 --- a/pcap-linux.c +++ b/pcap-linux.c @@ -245,12 +245,6 @@ static int pcap_setfilter_linux(pcap_t *, struct bpf_program *); static int pcap_setdirection_linux(pcap_t *, pcap_direction_t); static void pcap_cleanup_linux(pcap_t *); -union thdr { - struct tpacket_hdr *h1; - struct tpacket2_hdr *h2; - void *raw; -}; - #ifdef HAVE_PACKET_RING #define RING_GET_FRAME(h) (((union thdr **)h->buffer)[h->offset])