summaryrefslogtreecommitdiffstats
path: root/sys/net/if_tun.c
diff options
context:
space:
mode:
authorreyk <reyk@openbsd.org>2015-08-28 15:37:04 +0000
committerreyk <reyk@openbsd.org>2015-08-28 15:37:04 +0000
commit0e43911f14ce3ec06190d2f10431c1d561b8523a (patch)
treef95984f74a70b0058bc8d9499da2b977fdf136b0 /sys/net/if_tun.c
parentAdd support for Irix-style "64-bit" archives. (diff)
downloadwireguard-openbsd-0e43911f14ce3ec06190d2f10431c1d561b8523a.tar.xz
wireguard-openbsd-0e43911f14ce3ec06190d2f10431c1d561b8523a.zip
Fix compiling a kernel without NBPFILTER > 0.
OK mikeb@
Diffstat (limited to 'sys/net/if_tun.c')
-rw-r--r--sys/net/if_tun.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/net/if_tun.c b/sys/net/if_tun.c
index 8c81ce3680f..31cfdb929db 100644
--- a/sys/net/if_tun.c
+++ b/sys/net/if_tun.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_tun.c,v 1.151 2015/07/20 22:54:29 mpi Exp $ */
+/* $OpenBSD: if_tun.c,v 1.152 2015/08/28 15:37:04 reyk Exp $ */
/* $NetBSD: if_tun.c,v 1.24 1996/05/07 02:40:48 thorpej Exp $ */
/*
@@ -801,7 +801,10 @@ tunwrite(dev_t dev, struct uio *uio, int ioflag)
struct niqueue *ifq;
u_int32_t *th;
struct mbuf *top, **mp, *m;
- int error=0, s, tlen, mlen;
+ int error=0, tlen, mlen;
+#if NBPFILTER > 0
+ int s;
+#endif
if ((tp = tun_lookup(minor(dev))) == NULL)
return (ENXIO);