From: Amir Goldstein Date: Sun, 24 Sep 2017 10:01:35 +0000 (+0300) Subject: ovl: fix error value printed in ovl_lookup_index() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=e0082a0f04c432cb6d7128ef60d8e425e45ce025;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git ovl: fix error value printed in ovl_lookup_index() Fixes: 359f392ca53e ("ovl: lookup index entry for copy up origin") Cc: # v4.13 Signed-off-by: Amir Goldstein Signed-off-by: Miklos Szeredi --- diff --git a/fs/overlayfs/namei.c b/fs/overlayfs/namei.c index c3addd1114f1..654bea1a5ac9 100644 --- a/fs/overlayfs/namei.c +++ b/fs/overlayfs/namei.c @@ -506,6 +506,7 @@ static struct dentry *ovl_lookup_index(struct dentry *dentry, index = lookup_one_len_unlocked(name.name, ofs->indexdir, name.len); if (IS_ERR(index)) { + err = PTR_ERR(index); pr_warn_ratelimited("overlayfs: failed inode index lookup (ino=%lu, key=%*s, err=%i);\n" "overlayfs: mount with '-o index=off' to disable inodes index.\n", d_inode(origin)->i_ino, name.len, name.name,