|
@@ -523,9 +523,10 @@ static void path_put_conditional(struct path *path, struct nameidata *nd)
|
|
|
static inline void path_to_nameidata(struct path *path, struct nameidata *nd)
|
|
|
{
|
|
|
dput(nd->path.dentry);
|
|
|
- if (nd->path.mnt != path->mnt)
|
|
|
+ if (nd->path.mnt != path->mnt) {
|
|
|
mntput(nd->path.mnt);
|
|
|
- nd->path.mnt = path->mnt;
|
|
|
+ nd->path.mnt = path->mnt;
|
|
|
+ }
|
|
|
nd->path.dentry = path->dentry;
|
|
|
}
|
|
|
|