diff options
author | phk <phk@FreeBSD.org> | 1999-01-30 12:17:38 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 1999-01-30 12:17:38 +0000 |
commit | 67f187760e45386080ca97c6bc73608f9fe52ae5 (patch) | |
tree | 640104e6ae29a9d3ec3b379eab1297863b5d84c5 /sys/gnu/i386 | |
parent | 6c80ae4325fb5d1cab94603607c94d646aee0d8e (diff) | |
download | FreeBSD-src-67f187760e45386080ca97c6bc73608f9fe52ae5.zip FreeBSD-src-67f187760e45386080ca97c6bc73608f9fe52ae5.tar.gz |
Use suser() to check for super user rather than examining cr_uid directly.
Use TTYDEF_SPEED rather than 9600 a couple of places.
Reviewed by: bde, with a few grumbles.
Diffstat (limited to 'sys/gnu/i386')
-rw-r--r-- | sys/gnu/i386/isa/dgb.c | 5 | ||||
-rw-r--r-- | sys/gnu/i386/isa/dgm.c | 5 |
2 files changed, 6 insertions, 4 deletions
diff --git a/sys/gnu/i386/isa/dgb.c b/sys/gnu/i386/isa/dgb.c index 7aeb258..14211bc 100644 --- a/sys/gnu/i386/isa/dgb.c +++ b/sys/gnu/i386/isa/dgb.c @@ -1,5 +1,5 @@ /*- - * dgb.c $Id: dgb.c,v 1.40 1998/08/23 08:26:39 bde Exp $ + * dgb.c $Id: dgb.c,v 1.41 1998/12/07 21:58:17 archie Exp $ * * Digiboard driver. * @@ -1032,7 +1032,8 @@ open_top: goto open_top; } } - if (tp->t_state & TS_XCLUDE && p->p_ucred->cr_uid != 0) { + if (tp->t_state & TS_XCLUDE && + suser(p->p_ucred, &p->p_acflag)) { error = EBUSY; goto out; } diff --git a/sys/gnu/i386/isa/dgm.c b/sys/gnu/i386/isa/dgm.c index 8b0ca1f..9321bb9 100644 --- a/sys/gnu/i386/isa/dgm.c +++ b/sys/gnu/i386/isa/dgm.c @@ -1,5 +1,5 @@ /*- - * $Id: dgm.c,v 1.5 1998/08/23 08:26:40 bde Exp $ + * $Id: dgm.c,v 1.6 1998/12/07 21:58:18 archie Exp $ * * This driver and the associated header files support the ISA PC/Xem * Digiboards. Its evolutionary roots are described below. @@ -833,7 +833,8 @@ open_top: goto open_top; } } - if (tp->t_state & TS_XCLUDE && p->p_ucred->cr_uid != 0) { + if (tp->t_state & TS_XCLUDE && + suser(p->p_ucred, &p->p_acflag)) { error = EBUSY; goto out; } |