From 50894808ec86ebc46b53a62fc2ba537230cd62d1 Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Thu, 2 Jul 2009 12:31:02 -0700 Subject: [PATCH] If HAVE_PACKET_AUXDATA isn't defined, don't declare a variable that's used only if HAVE_PACKET_AUXDATA is defined. --- pcap-linux.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pcap-linux.c b/pcap-linux.c index 0e23fd0..0150226 100644 --- a/pcap-linux.c +++ b/pcap-linux.c @@ -2203,7 +2203,10 @@ activate_new(pcap_t *handle) #ifdef HAVE_PF_PACKET_SOCKETS const char *device = handle->opt.source; int is_any_device = (strcmp(device, "any") == 0); - int sock_fd = -1, arptype, val; + int sock_fd = -1, arptype; +#ifdef HAVE_PACKET_AUXDATA + int val; +#endif int err = 0; struct packet_mreq mr;