Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/kern Only check for ETXTBSY if the access would otherwis...
details: https://anonhg.NetBSD.org/src/rev/b91f4f07dec7
branches: trunk
changeset: 474166:b91f4f07dec7
user: is <is%NetBSD.org@localhost>
date: Wed Jun 30 10:00:06 1999 +0000
description:
Only check for ETXTBSY if the access would otherwise be allowed.
Needed to fix pr4134.
diffstat:
sys/kern/vfs_syscalls.c | 8 +++++---
1 files changed, 5 insertions(+), 3 deletions(-)
diffs (22 lines):
diff -r c635435cffc4 -r b91f4f07dec7 sys/kern/vfs_syscalls.c
--- a/sys/kern/vfs_syscalls.c Wed Jun 30 06:56:11 1999 +0000
+++ b/sys/kern/vfs_syscalls.c Wed Jun 30 10:00:06 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vfs_syscalls.c,v 1.137 1999/06/29 22:18:47 wrstuden Exp $ */
+/* $NetBSD: vfs_syscalls.c,v 1.138 1999/06/30 10:00:06 is Exp $ */
/*
* Copyright (c) 1989, 1993
@@ -1835,8 +1835,10 @@
flags |= VWRITE;
if (SCARG(uap, flags) & X_OK)
flags |= VEXEC;
- if ((flags & VWRITE) == 0 || (error = vn_writechk(vp)) == 0)
- error = VOP_ACCESS(vp, flags, cred, p);
+
+ error = VOP_ACCESS(vp, flags, cred, p);
+ if (!error && (flags & VWRITE))
+ error = vn_writechk(vp);
}
vput(vp);
out1:
Home |
Main Index |
Thread Index |
Old Index