Subject: Re: kern/767: another case of "panic: ufs_unlock NOT LOCKED"
To: None <moore@cs.utk.edu>
From: Keith Moore <moore@cs.utk.edu>
List: netbsd-bugs
Date: 01/30/1995 01:50:47
This seems to work as a fix. With this patch installed, the
sequence:
cd /some/directory
mount remote-host:/foo /some/directory
fails with EBUSY, as I think it should.
-Keith
*** vfs_syscalls.c.ORIG Wed Oct 5 21:18:28 1994
--- vfs_syscalls.c Sun Jan 29 21:06:59 1995
***************
*** 120,125 ****
--- 120,131 ----
}
if (error = vinvalbuf(vp, V_SAVE, p->p_ucred, p, 0, 0))
return (error);
+ #ifdef UTK
+ if (vp->v_usecount != 1) {
+ vput (vp);
+ return (EBUSY);
+ }
+ #endif
if (vp->v_type != VDIR) {
vput(vp);
return (ENOTDIR);