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

Commit d5dadb6c authored by Daniel Rosenberg's avatar Daniel Rosenberg
Browse files

ANDROID: sdcardfs: d_splice_alias can return error values



We must check that d_splice_alias was successful before using its
output.

Signed-off-by: default avatarDaniel Rosenberg <drosen@google.com>
Bug: 62390017
Change-Id: Ifda0a052fb3f67e35c635a4e5e907876c5400978
parent 4fce2666
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -199,6 +199,7 @@ static struct dentry *__sdcardfs_interpose(struct dentry *dentry,

	ret_dentry = d_splice_alias(inode, dentry);
	dentry = ret_dentry ?: dentry;
	if (!IS_ERR(dentry))
		update_derived_permission_lock(dentry);
out:
	return ret_dentry;