summaryrefslogtreecommitdiffstats
path: root/sys/dev/wl/if_wl.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/dev/wl/if_wl.c')
-rw-r--r--sys/dev/wl/if_wl.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/sys/dev/wl/if_wl.c b/sys/dev/wl/if_wl.c
index 42fc0f9..3370477 100644
--- a/sys/dev/wl/if_wl.c
+++ b/sys/dev/wl/if_wl.c
@@ -1,4 +1,4 @@
-/* $Id: if_wl.c,v 1.19 1998/12/09 03:30:51 eivind Exp $ */
+/* $Id: if_wl.c,v 1.20 1999/01/12 00:36:31 eivind Exp $ */
/*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -1294,7 +1294,7 @@ wlioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
/* pointer to buffer in user space */
up = (void *)ifr->ifr_data;
/* work out if they're root */
- isroot = (suser(p->p_ucred, &p->p_acflag) == 0);
+ isroot = (suser(p) == 0);
for (i = 0; i < 0x40; i++) {
/* don't hand the DES key out to non-root users */
@@ -1309,7 +1309,7 @@ wlioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
/* copy the PSA in from the caller; we only copy _some_ values */
case SIOCSWLPSA:
/* root only */
- if ((error = suser(p->p_ucred, &p->p_acflag)))
+ if ((error = suser(p)))
break;
error = EINVAL; /* assume the worst */
/* pointer to buffer in user space containing data */
@@ -1363,7 +1363,7 @@ wlioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
*/
case SIOCSWLCNWID:
/* root only */
- if ((error = suser(p->p_ucred, &p->p_acflag)))
+ if ((error = suser(p)))
break;
if (!(ifp->if_flags & IFF_UP)) {
error = EIO; /* only allowed while up */
@@ -1381,7 +1381,7 @@ wlioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
/* copy the EEPROM in 2.4 Gz WaveMODEM out to the caller */
case SIOCGWLEEPROM:
/* root only */
- if ((error = suser(p->p_ucred, &p->p_acflag)))
+ if ((error = suser(p)))
break;
/* pointer to buffer in user space */
up = (void *)ifr->ifr_data;
@@ -1404,7 +1404,7 @@ wlioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
/* zero (Delete) the wl cache */
case SIOCDWLCACHE:
/* root only */
- if ((error = suser(p->p_ucred, &p->p_acflag)))
+ if ((error = suser(p)))
break;
wl_cache_zero(unit);
break;
OpenPOWER on IntegriCloud