summaryrefslogtreecommitdiff
path: root/lib/libpcap
diff options
context:
space:
mode:
authorTed Unangst <tedu@cvs.openbsd.org>2004-02-06 22:41:25 +0000
committerTed Unangst <tedu@cvs.openbsd.org>2004-02-06 22:41:25 +0000
commit7f631c7e861e6fecb1d6886529f8e4dd11962fb9 (patch)
tree0404d22866f1396a5de94ab9756b9bf491a76e13 /lib/libpcap
parent72d59ef21c72c4554aa9dac9bed3bc02f7165483 (diff)
use the kernel default for buf size. no behavior change by default.
ok canacar@ mcbride@
Diffstat (limited to 'lib/libpcap')
-rw-r--r--lib/libpcap/pcap-bpf.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/libpcap/pcap-bpf.c b/lib/libpcap/pcap-bpf.c
index a8fb6b1edb0..f81375e0203 100644
--- a/lib/libpcap/pcap-bpf.c
+++ b/lib/libpcap/pcap-bpf.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pcap-bpf.c,v 1.15 2004/01/27 06:58:03 tedu Exp $ */
+/* $OpenBSD: pcap-bpf.c,v 1.16 2004/02/06 22:41:24 tedu Exp $ */
/*
* Copyright (c) 1993, 1994, 1995, 1996, 1998
@@ -197,6 +197,8 @@ pcap_open_live(char *device, int snaplen, int promisc, int to_ms, char *ebuf)
"kernel bpf filter out of date");
goto bad;
}
+#if 0
+ /* Just use the kernel default */
v = 32768; /* XXX this should be a user-accessible hook */
/* Ignore the return value - this is because the call fails on
* BPF systems that don't have kernel malloc. And if the call
@@ -204,6 +206,7 @@ pcap_open_live(char *device, int snaplen, int promisc, int to_ms, char *ebuf)
* buffer size.
*/
(void) ioctl(fd, BIOCSBLEN, (caddr_t)&v);
+#endif
(void)strlcpy(ifr.ifr_name, device, sizeof(ifr.ifr_name));
if (ioctl(fd, BIOCSETIF, (caddr_t)&ifr) < 0) {