From mboxrd@z Thu Jan 1 00:00:00 1970 From: "J. Bruce Fields" Subject: [PATCH 4/7] locks: break delegations on unlink Date: Fri, 9 Mar 2012 17:29:31 -0500 Message-ID: <1331332174-22621-4-git-send-email-bfields@redhat.com> References: <20120309222114.GA22423@fieldses.org> Cc: linux-nfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-fsdevel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Christoph Hellwig , "J. Bruce Fields" To: Al Viro Return-path: In-Reply-To: <20120309222114.GA22423-uC3wQj2KruNg9hUCZPvPmw@public.gmane.org> Sender: linux-nfs-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org List-Id: linux-fsdevel.vger.kernel.org From: "J. Bruce Fields" Signed-off-by: J. Bruce Fields --- fs/namei.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/fs/namei.c b/fs/namei.c index d29b3c4..eb4166f 100644 --- a/fs/namei.c +++ b/fs/namei.c @@ -2788,6 +2788,9 @@ static long do_unlinkat(int dfd, const char __user *pathname) error = security_path_unlink(&nd.path, dentry); if (error) goto exit3; + error = break_deleg(inode, O_WRONLY); + if (error) + goto exit3; error = vfs_unlink(nd.path.dentry->d_inode, dentry); exit3: mnt_drop_write(nd.path.mnt); -- 1.7.5.4 -- To unsubscribe from this list: send the line "unsubscribe linux-nfs" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html