Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 347789
b: refs/heads/master
c: 741b7c3
h: refs/heads/master
i:
  347787: 8a889d9
v: v3
  • Loading branch information
Al Viro committed Dec 20, 2012
1 parent b824327 commit e3e9b5b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 582aa64a04a579d47d05e4a0ee85bf047978ef4d
refs/heads/master: 741b7c3f77937b2fb7c10aeb4c5c621463582583
4 changes: 2 additions & 2 deletions trunk/fs/namei.c
Original file line number Diff line number Diff line change
Expand Up @@ -1859,7 +1859,7 @@ static int path_init(int dfd, const char *name, unsigned int flags,
if (flags & LOOKUP_ROOT) {
struct inode *inode = nd->root.dentry->d_inode;
if (*name) {
if (!inode->i_op->lookup)
if (!can_lookup(inode))
return -ENOTDIR;
retval = inode_permission(inode, MAY_EXEC);
if (retval)
Expand Down Expand Up @@ -1913,7 +1913,7 @@ static int path_init(int dfd, const char *name, unsigned int flags,
dentry = f.file->f_path.dentry;

if (*name) {
if (!S_ISDIR(dentry->d_inode->i_mode)) {
if (!can_lookup(dentry->d_inode)) {
fdput(f);
return -ENOTDIR;
}
Expand Down

0 comments on commit e3e9b5b

Please sign in to comment.