diff options
-rw-r--r-- | fs/proc/base.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/fs/proc/base.c b/fs/proc/base.c index c4a1ff371b8d..13e3ab99eb74 100644 --- a/fs/proc/base.c +++ b/fs/proc/base.c | |||
@@ -1196,7 +1196,8 @@ static struct inode_operations proc_pid_link_inode_operations = { | |||
1196 | 1196 | ||
1197 | static int proc_readfd(struct file * filp, void * dirent, filldir_t filldir) | 1197 | static int proc_readfd(struct file * filp, void * dirent, filldir_t filldir) |
1198 | { | 1198 | { |
1199 | struct inode *inode = filp->f_dentry->d_inode; | 1199 | struct dentry *dentry = filp->f_dentry; |
1200 | struct inode *inode = dentry->d_inode; | ||
1200 | struct task_struct *p = proc_task(inode); | 1201 | struct task_struct *p = proc_task(inode); |
1201 | unsigned int fd, tid, ino; | 1202 | unsigned int fd, tid, ino; |
1202 | int retval; | 1203 | int retval; |
@@ -1217,7 +1218,7 @@ static int proc_readfd(struct file * filp, void * dirent, filldir_t filldir) | |||
1217 | goto out; | 1218 | goto out; |
1218 | filp->f_pos++; | 1219 | filp->f_pos++; |
1219 | case 1: | 1220 | case 1: |
1220 | ino = fake_ino(tid, PROC_TID_INO); | 1221 | ino = parent_ino(dentry); |
1221 | if (filldir(dirent, "..", 2, 1, ino, DT_DIR) < 0) | 1222 | if (filldir(dirent, "..", 2, 1, ino, DT_DIR) < 0) |
1222 | goto out; | 1223 | goto out; |
1223 | filp->f_pos++; | 1224 | filp->f_pos++; |