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/i386/isa/istallion.c | |
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/i386/isa/istallion.c')
-rw-r--r-- | sys/i386/isa/istallion.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/sys/i386/isa/istallion.c b/sys/i386/isa/istallion.c index 51db908..e4040f7 100644 --- a/sys/i386/isa/istallion.c +++ b/sys/i386/isa/istallion.c @@ -33,7 +33,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id: istallion.c,v 1.22 1998/08/23 09:57:09 bde Exp $ + * $Id: istallion.c,v 1.23 1999/01/12 01:17:01 eivind Exp $ */ /*****************************************************************************/ @@ -129,7 +129,7 @@ #define STL_MEMDEV 0x07000000 -#define STL_DEFSPEED 9600 +#define STL_DEFSPEED TTYDEF_SPEED #define STL_DEFCFLAG (CS8 | CREAD | HUPCL) /*****************************************************************************/ @@ -1009,7 +1009,8 @@ stliopen_restart: goto stliopen_restart; } } - 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 stliopen_end; } |