summaryrefslogtreecommitdiff
path: root/src/kernel/fd.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/kernel/fd.c')
-rw-r--r--src/kernel/fd.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/kernel/fd.c b/src/kernel/fd.c
index 54f1c72..7d448eb 100644
--- a/src/kernel/fd.c
+++ b/src/kernel/fd.c
@@ -2,9 +2,8 @@
#include <kernel/panic.h>
#include <kernel/proc.h>
-int fdop_dispatch(enum fdop fdop, fd_t fd, void *ptr, size_t len) {
- if (fd < 0 || fd >= FD_MAX) return -1;
- switch(process_current->fds[fd].type) {
+int fdop_dispatch(enum fdop fdop, struct fd *fd, void *ptr, size_t len) {
+ switch(fd->type) {
case FD_EMPTY:
return -1;
default: