projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
443ed25
)
Add missing unlocks to error paths of mountpoint_last.
author
Dave Jones
<
[email protected]
>
Tue, 10 Sep 2013 21:04:25 +0000
(17:04 -0400)
committer
Al Viro
<
[email protected]
>
Tue, 10 Sep 2013 21:09:32 +0000
(17:09 -0400)
Signed-off-by: Dave Jones <
[email protected]
>
Signed-off-by: Al Viro <
[email protected]
>
fs/namei.c
patch
|
blob
|
history
diff --git
a/fs/namei.c
b/fs/namei.c
index 841c8d9286c02514c449f1121b3f1c71717a2e1b..0dc4cbf21f377681aa611578a38ab80c0af24646 100644
(file)
--- a/
fs/namei.c
+++ b/
fs/namei.c
@@
-2261,12
+2261,15
@@
mountpoint_last(struct nameidata *nd, struct path *path)
dentry = d_alloc(dir, &nd->last);
if (!dentry) {
error = -ENOMEM;
+ mutex_unlock(&dir->d_inode->i_mutex);
goto out;
}
dentry = lookup_real(dir->d_inode, dentry, nd->flags);
error = PTR_ERR(dentry);
- if (IS_ERR(dentry))
+ if (IS_ERR(dentry)) {
+ mutex_unlock(&dir->d_inode->i_mutex);
goto out;
+ }
}
mutex_unlock(&dir->d_inode->i_mutex);