diff options
Diffstat (limited to 'fs/open.c')
-rw-r--r-- | fs/open.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -836,7 +836,7 @@ EXPORT_SYMBOL(dentry_open); | |||
836 | static void __put_unused_fd(struct files_struct *files, unsigned int fd) | 836 | static void __put_unused_fd(struct files_struct *files, unsigned int fd) |
837 | { | 837 | { |
838 | struct fdtable *fdt = files_fdtable(files); | 838 | struct fdtable *fdt = files_fdtable(files); |
839 | __FD_CLR(fd, fdt->open_fds); | 839 | __clear_open_fd(fd, fdt); |
840 | if (fd < files->next_fd) | 840 | if (fd < files->next_fd) |
841 | files->next_fd = fd; | 841 | files->next_fd = fd; |
842 | } | 842 | } |
@@ -1080,7 +1080,7 @@ SYSCALL_DEFINE1(close, unsigned int, fd) | |||
1080 | if (!filp) | 1080 | if (!filp) |
1081 | goto out_unlock; | 1081 | goto out_unlock; |
1082 | rcu_assign_pointer(fdt->fd[fd], NULL); | 1082 | rcu_assign_pointer(fdt->fd[fd], NULL); |
1083 | FD_CLR(fd, fdt->close_on_exec); | 1083 | __clear_close_on_exec(fd, fdt); |
1084 | __put_unused_fd(files, fd); | 1084 | __put_unused_fd(files, fd); |
1085 | spin_unlock(&files->file_lock); | 1085 | spin_unlock(&files->file_lock); |
1086 | retval = filp_close(filp, files); | 1086 | retval = filp_close(filp, files); |