diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2016-12-01 10:31:53 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2016-12-01 10:31:53 -0800 |
commit | 2caceb3294a78c389b462e7e236a4e744a53a474 (patch) | |
tree | cbdfc4d847410a665dbe9f75b828494c63c00377 /fs | |
parent | 92cf44e284d0c2e456d43c0951107a4ec046ef1c (diff) | |
parent | c4fcfc1619ea43a8a89ad2f83ff23905eee088bd (diff) | |
download | linux-2caceb3294a78c389b462e7e236a4e744a53a474.tar.bz2 |
Merge branch 'overlayfs-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/vfs
Pull overlayfs fix from Miklos Szeredi:
"This fixes a regression introduced in 4.8"
* 'overlayfs-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/vfs:
ovl: fix d_real() for stacked fs
Diffstat (limited to 'fs')
-rw-r--r-- | fs/overlayfs/super.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/overlayfs/super.c b/fs/overlayfs/super.c index edd46a0e951d..0e100856c7b8 100644 --- a/fs/overlayfs/super.c +++ b/fs/overlayfs/super.c @@ -328,11 +328,11 @@ static struct dentry *ovl_d_real(struct dentry *dentry, if (!real) goto bug; + /* Handle recursion */ + real = d_real(real, inode, open_flags); + if (!inode || inode == d_inode(real)) return real; - - /* Handle recursion */ - return d_real(real, inode, open_flags); bug: WARN(1, "ovl_d_real(%pd4, %s:%lu): real dentry not found\n", dentry, inode ? inode->i_sb->s_id : "NULL", inode ? inode->i_ino : 0); |