diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2016-04-20 17:08:21 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2016-05-02 19:49:28 -0400 |
commit | 63b6df14134ddd048984c8afadb46e721815bfc6 (patch) | |
tree | 7fecdc7f3ee6d9780b3fa5328a0acd1bb739b16e /arch/alpha | |
parent | 9902af79c01a8e39bb99b922fa3eef6d4ea23d69 (diff) |
give readdir(2)/getdents(2)/etc. uniform exclusion with lseek()
same as read() on regular files has, and for the same reason.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'arch/alpha')
-rw-r--r-- | arch/alpha/kernel/osf_sys.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/alpha/kernel/osf_sys.c b/arch/alpha/kernel/osf_sys.c index 6cc08166ff00..ffb93f499c83 100644 --- a/arch/alpha/kernel/osf_sys.c +++ b/arch/alpha/kernel/osf_sys.c | |||
@@ -147,7 +147,7 @@ SYSCALL_DEFINE4(osf_getdirentries, unsigned int, fd, | |||
147 | long __user *, basep) | 147 | long __user *, basep) |
148 | { | 148 | { |
149 | int error; | 149 | int error; |
150 | struct fd arg = fdget(fd); | 150 | struct fd arg = fdget_pos(fd); |
151 | struct osf_dirent_callback buf = { | 151 | struct osf_dirent_callback buf = { |
152 | .ctx.actor = osf_filldir, | 152 | .ctx.actor = osf_filldir, |
153 | .dirent = dirent, | 153 | .dirent = dirent, |
@@ -164,7 +164,7 @@ SYSCALL_DEFINE4(osf_getdirentries, unsigned int, fd, | |||
164 | if (count != buf.count) | 164 | if (count != buf.count) |
165 | error = count - buf.count; | 165 | error = count - buf.count; |
166 | 166 | ||
167 | fdput(arg); | 167 | fdput_pos(arg); |
168 | return error; | 168 | return error; |
169 | } | 169 | } |
170 | 170 | ||