summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authormatthew <matthew@openbsd.org>2010-09-22 05:44:27 +0000
committermatthew <matthew@openbsd.org>2010-09-22 05:44:27 +0000
commit191feee13dd5b33d2da884c7ebf618da98f6de39 (patch)
tree9dbea400d0321354a55d60848710e5989b682baa /sys
parentGarbage collect the field dk_labelsector since there are no uses (diff)
downloadwireguard-openbsd-191feee13dd5b33d2da884c7ebf618da98f6de39.tar.xz
wireguard-openbsd-191feee13dd5b33d2da884c7ebf618da98f6de39.zip
Don't bother calling suser() in tunopen().
"Sure" deraadt@
Diffstat (limited to 'sys')
-rw-r--r--sys/net/if_tun.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/sys/net/if_tun.c b/sys/net/if_tun.c
index 2e4b3ee9391..ba9ce52790d 100644
--- a/sys/net/if_tun.c
+++ b/sys/net/if_tun.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_tun.c,v 1.107 2010/07/08 08:40:29 yasuoka Exp $ */
+/* $OpenBSD: if_tun.c,v 1.108 2010/09/22 05:44:27 matthew Exp $ */
/* $NetBSD: if_tun.c,v 1.24 1996/05/07 02:40:48 thorpej Exp $ */
/*
@@ -343,9 +343,6 @@ tunopen(dev_t dev, int flag, int mode, struct proc *p)
struct ifnet *ifp;
int error, s;
- if ((error = suser(p, 0)) != 0)
- return (error);
-
if ((tp = tun_lookup(minor(dev))) == NULL) { /* create on demand */
char xname[IFNAMSIZ];