aboutsummaryrefslogtreecommitdiff
path: root/pcap-linux.c
diff options
context:
space:
mode:
Diffstat (limited to 'pcap-linux.c')
-rw-r--r--pcap-linux.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/pcap-linux.c b/pcap-linux.c
index 7a05ff29..a83f418d 100644
--- a/pcap-linux.c
+++ b/pcap-linux.c
@@ -4086,6 +4086,7 @@ static int pcap_wait_for_frames_mmap(pcap_t *handle)
pollinfo.events = POLLIN;
if (handlep->timeout == 0) {
+#ifdef TPACKET_V3
/*
* XXX - due to a set of (mis)features in the
* TPACKET_V3 kernel code, blocking forever with
@@ -4106,6 +4107,7 @@ static int pcap_wait_for_frames_mmap(pcap_t *handle)
if (handlep->tp_version == TPACKET_V3)
timeout = 1; /* don't block for very long */
else
+#endif
timeout = -1; /* block forever */
} else if (handlep->timeout > 0)
timeout = handlep->timeout; /* block for that amount of time */