Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7168179f authored by Amir Goldstein's avatar Amir Goldstein Committed by Miklos Szeredi
Browse files

ovl: check ERR_PTR() return value from ovl_lookup_real()



Reported-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Fixes: 06170154 ("ovl: lookup indexed ancestor of lower dir")
Signed-off-by: default avatarAmir Goldstein <amir73il@gmail.com>
Signed-off-by: default avatarMiklos Szeredi <mszeredi@redhat.com>
parent 2ca3c148
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -477,8 +477,8 @@ static struct dentry *ovl_lookup_real_inode(struct super_block *sb,
		dput(upper);
	}

	if (!this)
		return NULL;
	if (IS_ERR_OR_NULL(this))
		return this;

	if (WARN_ON(ovl_dentry_real_at(this, layer->idx) != real)) {
		dput(this);