aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--fs/xattr.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/fs/xattr.c b/fs/xattr.c
index 4d45b7189e7e..107f457143c3 100644
--- a/fs/xattr.c
+++ b/fs/xattr.c
@@ -295,11 +295,13 @@ vfs_removexattr(struct dentry *dentry, const char *name)
295 if (error) 295 if (error)
296 return error; 296 return error;
297 297
298 mutex_lock(&inode->i_mutex);
298 error = security_inode_removexattr(dentry, name); 299 error = security_inode_removexattr(dentry, name);
299 if (error) 300 if (error) {
301 mutex_unlock(&inode->i_mutex);
300 return error; 302 return error;
303 }
301 304
302 mutex_lock(&inode->i_mutex);
303 error = inode->i_op->removexattr(dentry, name); 305 error = inode->i_op->removexattr(dentry, name);
304 mutex_unlock(&inode->i_mutex); 306 mutex_unlock(&inode->i_mutex);
305 307