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:
ab10492
)
namei: may_follow_link() - lift terminate_walk() on failures into caller
author
Al Viro
<viro@zeniv.linux.org.uk>
Fri, 8 May 2015 20:38:31 +0000
(16:38 -0400)
committer
Al Viro
<viro@zeniv.linux.org.uk>
Mon, 11 May 2015 02:20:20 +0000
(22:20 -0400)
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
fs/namei.c
patch
|
blob
|
history
diff --git
a/fs/namei.c
b/fs/namei.c
index 6d4692d772f749736ad5e697dd4c6b96429c8841..51e2214e820d09d32fd68317ebdfc8bbfb98e74f 100644
(file)
--- a/
fs/namei.c
+++ b/
fs/namei.c
@@
-798,7
+798,6
@@
static inline int may_follow_link(struct nameidata *nd)
return 0;
audit_log_link_denied("follow_link", &nd->stack[0].link);
- terminate_walk(nd);
return -EACCES;
}
@@
-1980,8
+1979,10
@@
static int trailing_symlink(struct nameidata *nd)
{
const char *s;
int error = may_follow_link(nd);
- if (unlikely(error))
+ if (unlikely(error)) {
+ terminate_walk(nd);
return error;
+ }
nd->flags |= LOOKUP_PARENT;
nd->stack[0].name = NULL;
s = get_link(nd);