Commit 0aa7720d authored by Andy Whitcroft's avatar Andy Whitcroft Committed by Tim Gardner

UBUNTU: SAUCE: overlayfs: fix regression in whiteout detection

The Ubuntu backport of the below commit necessarily had to follow the
changes to is_ovl_whiteout.  In the process the wrong dentry was passed
preventing correct detection of legacy whitouts in a rename over a
whitout on some upper filesystem types (at least ramfs):

  commit 11f37104
  Author: Miklos Szeredi <mszeredi@redhat.com>
  Date:   Mon Mar 21 17:31:44 2016 +0100

    ovl: verify upper dentry before unlink and rename

Pass the correct dentry to allow detection of the appropriate whiteout
types.

Fixes: 11f37104 ("ovl: verify upper dentry before unlink and rename") in Ubuntu
BugLink: http://bugs.launchpad.net/bugs/1618572Signed-off-by: default avatarAndy Whitcroft <apw@canonical.com>
Acked-by: default avatarStefan Bader <stefan.bader@canonical.com>
Signed-off-by: default avatarTim Gardner <tim.gardner@canonical.com>
parent aa6d67a7
......@@ -919,7 +919,7 @@ static int ovl_rename2(struct inode *olddir, struct dentry *old,
} else {
new_create = true;
if (!d_is_negative(newdentry) &&
(!new_opaque || !ovl_is_whiteout(newdentry,ovl_config_legacy(newdentry))))
(!new_opaque || !ovl_is_whiteout(newdentry,ovl_config_legacy(new))))
goto out_dput;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment