summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorAhmad Fatoum <a.fatoum@pengutronix.de>2023-09-11 14:25:04 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2023-09-12 10:38:36 +0200
commite1f79b61b86a66be120d8caf20184da5e5f96457 (patch)
tree58f1d815b44197c77c2dee1541aba298ee517557 /fs
parent4411b931680e4fb15d6f80e5543ef9f81aef092b (diff)
downloadbarebox-e1f79b61b86a66be120d8caf20184da5e5f96457.tar.gz
barebox-e1f79b61b86a66be120d8caf20184da5e5f96457.tar.xz
fs: ext4: initialize variable to silence GCC false-positive
GCC complains about ino not being defined in some cases, which appears to be a false positive. Nevertheless, initialize it to the same fallback value used in ext4fs_get_ino, which is called below. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20230911122504.2720431-1-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'fs')
-rw-r--r--fs/ext4/ext_barebox.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/ext4/ext_barebox.c b/fs/ext4/ext_barebox.c
index 93dc9b4b14..df82b629cd 100644
--- a/fs/ext4/ext_barebox.c
+++ b/fs/ext4/ext_barebox.c
@@ -118,7 +118,7 @@ static struct dentry *ext_lookup(struct inode *dir, struct dentry *dentry,
unsigned int flags)
{
struct ext2fs_node *e2dir = to_ext2_node(dir);
- int ret, ino;
+ int ret, ino = 0;
struct inode *inode;
ret = ext4fs_get_ino(e2dir, &dentry->d_name, &ino);