projects
/
unix-history
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
tags
|
clone url
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
delete VERBOSE #ifdef's
[unix-history]
/
usr
/
src
/
sys
/
kern
/
tty_tty.c
diff --git
a/usr/src/sys/kern/tty_tty.c
b/usr/src/sys/kern/tty_tty.c
index
6570510
..
954813e
100644
(file)
--- a/
usr/src/sys/kern/tty_tty.c
+++ b/
usr/src/sys/kern/tty_tty.c
@@
-4,7
+4,7
@@
*
* %sccs.include.redist.c%
*
*
* %sccs.include.redist.c%
*
- * @(#)tty_tty.c 7.1
4
(Berkeley) %G%
+ * @(#)tty_tty.c 7.1
9
(Berkeley) %G%
*/
/*
*/
/*
@@
-14,8
+14,8
@@
#include "systm.h"
#include "conf.h"
#include "ioctl.h"
#include "systm.h"
#include "conf.h"
#include "ioctl.h"
-#include "tty.h"
#include "proc.h"
#include "proc.h"
+#include "tty.h"
#include "vnode.h"
#include "file.h"
#include "vnode.h"
#include "file.h"
@@
-35,16
+35,17
@@
cttyopen(dev, flag, mode, p)
VOP_LOCK(ttyvp);
error = VOP_ACCESS(ttyvp,
(flag&FREAD ? VREAD : 0) | (flag&FWRITE ? VWRITE : 0), p->p_ucred, p);
VOP_LOCK(ttyvp);
error = VOP_ACCESS(ttyvp,
(flag&FREAD ? VREAD : 0) | (flag&FWRITE ? VWRITE : 0), p->p_ucred, p);
+ if (!error)
+ error = VOP_OPEN(ttyvp, flag, NOCRED, p);
VOP_UNLOCK(ttyvp);
VOP_UNLOCK(ttyvp);
- if (error)
- return (error);
- return (VOP_OPEN(ttyvp, flag, NOCRED, p));
+ return (error);
}
/*ARGSUSED*/
cttyread(dev, uio, flag)
dev_t dev;
struct uio *uio;
}
/*ARGSUSED*/
cttyread(dev, uio, flag)
dev_t dev;
struct uio *uio;
+ int flag;
{
register struct vnode *ttyvp = cttyvp(uio->uio_procp);
int error;
{
register struct vnode *ttyvp = cttyvp(uio->uio_procp);
int error;
@@
-61,6
+62,7
@@
cttyread(dev, uio, flag)
cttywrite(dev, uio, flag)
dev_t dev;
struct uio *uio;
cttywrite(dev, uio, flag)
dev_t dev;
struct uio *uio;
+ int flag;
{
register struct vnode *ttyvp = cttyvp(uio->uio_procp);
int error;
{
register struct vnode *ttyvp = cttyvp(uio->uio_procp);
int error;