]> git.baikalelectronics.ru Git - kernel.git/commit
btrfs: return error instead of crash when detecting unexpected type in btrfs_get_acl
authorChengguang Xu <cgxu519@gmx.com>
Wed, 27 Jun 2018 04:16:34 +0000 (12:16 +0800)
committerDavid Sterba <dsterba@suse.com>
Mon, 6 Aug 2018 11:12:40 +0000 (13:12 +0200)
commit3e7cf3272d363196a1cfc2674e437b40172dda43
tree45fb7a3623160b31e26cfd7e5732226404641aee
parentee962c337d5e344169a7f63dec54a02e2ab70964
btrfs: return error instead of crash when detecting unexpected type in btrfs_get_acl

The caller of btrfs_get_acl() checks error condition so there is no
impact from this change. In practice there is no chance to get into
default case of switch statement because VFS has already checked the
type.

Signed-off-by: Chengguang Xu <cgxu519@gmx.com>
Reviewed-by: Nikolay Borisov <nborisov@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/acl.c