aboutsummaryrefslogtreecommitdiffstats
path: root/fs/namei.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/namei.c')
-rw-r--r--fs/namei.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/namei.c b/fs/namei.c
index e42f7c35545a..020fb8c8d1cd 100644
--- a/fs/namei.c
+++ b/fs/namei.c
@@ -1524,8 +1524,10 @@ do_link:
1524 error = security_inode_follow_link(path.dentry, nd); 1524 error = security_inode_follow_link(path.dentry, nd);
1525 if (error) 1525 if (error)
1526 goto exit_dput; 1526 goto exit_dput;
1527 mntget(path.mnt);
1527 error = __do_follow_link(path.dentry, nd); 1528 error = __do_follow_link(path.dentry, nd);
1528 dput(path.dentry); 1529 dput(path.dentry);
1530 mntput(path.mnt);
1529 path.mnt = nd->mnt; 1531 path.mnt = nd->mnt;
1530 if (error) 1532 if (error)
1531 return error; 1533 return error;