diff options
Diffstat (limited to 'fs/namei.c')
| -rw-r--r-- | fs/namei.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/fs/namei.c b/fs/namei.c index b753192d8c3f..7d77f24d32a9 100644 --- a/fs/namei.c +++ b/fs/namei.c | |||
| @@ -1272,8 +1272,10 @@ done: | |||
| 1272 | path->mnt = mnt; | 1272 | path->mnt = mnt; |
| 1273 | path->dentry = dentry; | 1273 | path->dentry = dentry; |
| 1274 | err = follow_managed(path, nd->flags); | 1274 | err = follow_managed(path, nd->flags); |
| 1275 | if (unlikely(err < 0)) | 1275 | if (unlikely(err < 0)) { |
| 1276 | path_put_conditional(path, nd); | ||
| 1276 | return err; | 1277 | return err; |
| 1278 | } | ||
| 1277 | *inode = path->dentry->d_inode; | 1279 | *inode = path->dentry->d_inode; |
| 1278 | return 0; | 1280 | return 0; |
| 1279 | 1281 | ||
