Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 1854
b: refs/heads/master
c: d9d29a2
h: refs/heads/master
v: v3
  • Loading branch information
Al Viro authored and Linus Torvalds committed Jun 6, 2005
1 parent 3153cbe commit 660d2c2
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 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: 4b7b9772e4c3d87e649d4c419d2487aacf1235aa
refs/heads/master: d9d29a29669f96903d9950bb881c2a393fd33849
11 changes: 5 additions & 6 deletions trunk/fs/namei.c
Original file line number Diff line number Diff line change
Expand Up @@ -544,15 +544,15 @@ static inline int do_follow_link(struct path *path, struct nameidata *nd)
current->total_link_count++;
nd->depth++;
if (path->mnt != nd->mnt)
mntput(nd->mnt);
mntput(path->mnt);
err = __do_follow_link(path, nd);
current->link_count--;
nd->depth--;
return err;
loop:
if (path->mnt != nd->mnt)
mntput(nd->mnt);
dput(path->dentry);
if (path->mnt != nd->mnt)
mntput(path->mnt);
path_release(nd);
return err;
}
Expand Down Expand Up @@ -906,7 +906,7 @@ static fastcall int __link_path_walk(const char * name, struct nameidata *nd)
out_dput:
dput(next.dentry);
if (nd->mnt != next.mnt)
mntput(nd->mnt);
mntput(next.mnt);
break;
}
path_release(nd);
Expand Down Expand Up @@ -1551,8 +1551,7 @@ int open_namei(const char * pathname, int flag, int mode, struct nameidata *nd)
if (error)
goto exit_dput;
if (nd->mnt != path.mnt)
mntput(nd->mnt);
nd->mnt = path.mnt;
mntput(path.mnt);
error = __do_follow_link(&path, nd);
if (error)
return error;
Expand Down

0 comments on commit 660d2c2

Please sign in to comment.