]> git.baikalelectronics.ru Git - kernel.git/commit
ext4: fix unused-but-set-variable warning in ext4_add_entry()
authorYunfeng Ye <yeyunfeng@huawei.com>
Tue, 17 Dec 2019 14:46:49 +0000 (22:46 +0800)
committerTheodore Ts'o <tytso@mit.edu>
Sun, 22 Dec 2019 02:00:53 +0000 (21:00 -0500)
commitf6335167a7a03f9f877d876bf2b9ca6c0aa0b1cf
treedbd98a4c0749e6878b5a01dc522c08fe9b291171
parent72ad285f93a3d70579e6fcfd3ccda504f149893d
ext4: fix unused-but-set-variable warning in ext4_add_entry()

Warning is found when compile with "-Wunused-but-set-variable":

fs/ext4/namei.c: In function ‘ext4_add_entry’:
fs/ext4/namei.c:2167:23: warning: variable ‘sbi’ set but not used
[-Wunused-but-set-variable]
  struct ext4_sb_info *sbi;
                       ^~~
Fix this by moving the variable @sbi under CONFIG_UNICODE.

Signed-off-by: Yunfeng Ye <yeyunfeng@huawei.com>
Reviewed-by: Ritesh Harjani <riteshh@linux.ibm.com>
Link: https://lore.kernel.org/r/cb5eb904-224a-9701-c38f-cb23514b1fff@huawei.com
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
fs/ext4/namei.c