]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
btrfs: rename error to ret in btrfs_may_delete()
authorDavid Sterba <dsterba@suse.com>
Wed, 18 Jun 2025 11:29:27 +0000 (13:29 +0200)
committerDavid Sterba <dsterba@suse.com>
Mon, 21 Jul 2025 21:58:03 +0000 (23:58 +0200)
Unify naming of return value to the preferred way.

Reviewed-by: Daniel Vacek <neelx@suse.com>yy
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/ioctl.c

index fb5097695f6d8b72057da7e381ef56ec003aa39e..a2450766a503bac288ede8ea060fb93d5e28d8f8 100644 (file)
@@ -841,7 +841,7 @@ free_pending:
 static int btrfs_may_delete(struct mnt_idmap *idmap,
                            struct inode *dir, struct dentry *victim, int isdir)
 {
-       int error;
+       int ret;
 
        if (d_really_is_negative(victim))
                return -ENOENT;
@@ -851,9 +851,9 @@ static int btrfs_may_delete(struct mnt_idmap *idmap,
                return -EINVAL;
        audit_inode_child(dir, victim, AUDIT_TYPE_CHILD_DELETE);
 
-       error = inode_permission(idmap, dir, MAY_WRITE | MAY_EXEC);
-       if (error)
-               return error;
+       ret = inode_permission(idmap, dir, MAY_WRITE | MAY_EXEC);
+       if (ret)
+               return ret;
        if (IS_APPEND(dir))
                return -EPERM;
        if (check_sticky(idmap, dir, d_inode(victim)) ||