- Honor the cn_lkflags passed from namei() when locking the leaf.
Sponsored by: Isilon Systems, Inc.
This commit is contained in:
parent
571211c454
commit
a69c43548d
@ -565,7 +565,7 @@ ufs_lookup(ap)
|
|||||||
if (flags & ISDOTDOT) {
|
if (flags & ISDOTDOT) {
|
||||||
VOP_UNLOCK(pdp, 0, td); /* race to get the inode */
|
VOP_UNLOCK(pdp, 0, td); /* race to get the inode */
|
||||||
error = VFS_VGET(pdp->v_mount, dp->i_ino,
|
error = VFS_VGET(pdp->v_mount, dp->i_ino,
|
||||||
LK_EXCLUSIVE, &tdp);
|
cnp->cn_lkflags, &tdp);
|
||||||
if (error) {
|
if (error) {
|
||||||
vn_lock(pdp, LK_EXCLUSIVE | LK_RETRY, td);
|
vn_lock(pdp, LK_EXCLUSIVE | LK_RETRY, td);
|
||||||
return (error);
|
return (error);
|
||||||
@ -575,7 +575,8 @@ ufs_lookup(ap)
|
|||||||
VREF(vdp); /* we want ourself, ie "." */
|
VREF(vdp); /* we want ourself, ie "." */
|
||||||
*vpp = vdp;
|
*vpp = vdp;
|
||||||
} else {
|
} else {
|
||||||
error = VFS_VGET(pdp->v_mount, dp->i_ino, LK_EXCLUSIVE, &tdp);
|
error = VFS_VGET(pdp->v_mount, dp->i_ino,
|
||||||
|
cnp->cn_lkflags, &tdp);
|
||||||
if (error)
|
if (error)
|
||||||
return (error);
|
return (error);
|
||||||
*vpp = tdp;
|
*vpp = tdp;
|
||||||
|
Loading…
Reference in New Issue
Block a user