summaryrefslogtreecommitdiffstats
path: root/sys/fs
diff options
context:
space:
mode:
Diffstat (limited to 'sys/fs')
-rw-r--r--sys/fs/fdescfs/fdesc_vnops.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/fs/fdescfs/fdesc_vnops.c b/sys/fs/fdescfs/fdesc_vnops.c
index 61dd48e..90c4be0 100644
--- a/sys/fs/fdescfs/fdesc_vnops.c
+++ b/sys/fs/fdescfs/fdesc_vnops.c
@@ -401,12 +401,12 @@ fdesc_setattr(ap)
return (error);
}
vp = fp->f_vnode;
- vn_lock(vp, LK_EXCLUSIVE | LK_RETRY, ap->a_td);
if ((error = vn_start_write(vp, &mp, V_WAIT | PCATCH)) == 0) {
+ vn_lock(vp, LK_EXCLUSIVE | LK_RETRY, ap->a_td);
error = VOP_SETATTR(vp, ap->a_vap, ap->a_cred, ap->a_td);
+ VOP_UNLOCK(vp, 0, ap->a_td);
vn_finished_write(mp);
}
- VOP_UNLOCK(vp, 0, ap->a_td);
fdrop(fp, ap->a_td);
return (error);
}
OpenPOWER on IntegriCloud