summaryrefslogtreecommitdiff
path: root/sys/compat/common
diff options
context:
space:
mode:
authorConstantine Sapuntzakis <csapuntz@cvs.openbsd.org>1997-11-06 05:59:40 +0000
committerConstantine Sapuntzakis <csapuntz@cvs.openbsd.org>1997-11-06 05:59:40 +0000
commit4e165724f1631d1deee6fd89b941fabdbcc855d4 (patch)
tree3aca36af68e90377984b00e9f0050674b0763db5 /sys/compat/common
parentfec1be888534eb37405f6bf7a195f28670e1392b (diff)
Updates for VFS Lite 2 + soft update.
Diffstat (limited to 'sys/compat/common')
-rw-r--r--sys/compat/common/kern_info_09.c3
-rw-r--r--sys/compat/common/vfs_syscalls_43.c9
2 files changed, 7 insertions, 5 deletions
diff --git a/sys/compat/common/kern_info_09.c b/sys/compat/common/kern_info_09.c
index 4481b58323d..54bd6668f84 100644
--- a/sys/compat/common/kern_info_09.c
+++ b/sys/compat/common/kern_info_09.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: kern_info_09.c,v 1.5 1997/10/06 20:19:26 deraadt Exp $ */
+/* $OpenBSD: kern_info_09.c,v 1.6 1997/11/06 05:58:02 csapuntz Exp $ */
/* $NetBSD: kern_info_09.c,v 1.5 1996/02/21 00:10:59 cgd Exp $ */
/*
@@ -127,6 +127,7 @@ compat_09_sys_uname(p, v, retval)
*dp++ = *cp;
*dp = '\0';
strncpy(outsname.machine, MACHINE, sizeof(outsname.machine));
+
return (copyout((caddr_t)&outsname, (caddr_t)SCARG(uap, name),
sizeof(struct outsname)));
}
diff --git a/sys/compat/common/vfs_syscalls_43.c b/sys/compat/common/vfs_syscalls_43.c
index 9006dfc65f3..c7760d185a2 100644
--- a/sys/compat/common/vfs_syscalls_43.c
+++ b/sys/compat/common/vfs_syscalls_43.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: vfs_syscalls_43.c,v 1.7 1997/10/06 20:19:27 deraadt Exp $ */
+/* $OpenBSD: vfs_syscalls_43.c,v 1.8 1997/11/06 05:58:02 csapuntz Exp $ */
/* $NetBSD: vfs_syscalls_43.c,v 1.4 1996/03/14 19:31:52 christos Exp $ */
/*
@@ -387,7 +387,8 @@ unionread:
auio.uio_segflg = UIO_USERSPACE;
auio.uio_procp = p;
auio.uio_resid = SCARG(uap, count);
- VOP_LOCK(vp);
+
+ vn_lock(vp, LK_EXCLUSIVE | LK_RETRY, p);
loff = auio.uio_offset = fp->f_offset;
# if (BYTE_ORDER != LITTLE_ENDIAN)
if (vp->v_mount->mnt_maxsymlinklen <= 0) {
@@ -404,7 +405,7 @@ unionread:
MALLOC(dirbuf, caddr_t, SCARG(uap, count), M_TEMP, M_WAITOK);
kiov.iov_base = dirbuf;
error = VOP_READDIR(vp, &kuio, fp->f_cred, &eofflag,
- (u_long *)0, 0);
+ 0, 0);
fp->f_offset = kuio.uio_offset;
if (error == 0) {
readcnt = SCARG(uap, count) - kuio.uio_resid;
@@ -440,7 +441,7 @@ unionread:
}
FREE(dirbuf, M_TEMP);
}
- VOP_UNLOCK(vp);
+ VOP_UNLOCK(vp, 0, p);
if (error)
return (error);
if ((SCARG(uap, count) == auio.uio_resid) &&