summaryrefslogtreecommitdiff
path: root/src/kernel/syscalls.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/kernel/syscalls.c')
-rw-r--r--src/kernel/syscalls.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/kernel/syscalls.c b/src/kernel/syscalls.c
index 1909eb7..6800138 100644
--- a/src/kernel/syscalls.c
+++ b/src/kernel/syscalls.c
@@ -86,9 +86,8 @@ handle_t _syscall_open(const char __user *path, long len, int flags) {
if (PATH_MAX < len)
SYSCALL_RETURN(-1);
- // TODO remove this check - it's not worth it w/ threads
- if (process_find_free_handle(process_current, 0) < 0)
- SYSCALL_RETURN(-EMFILE);
+ /* Doesn't check for free handles. Another thread could use up all
+ * handles in the meantime anyways, or free some up. */
path_buf = kmalloc(len);
if (!path_buf) goto fail;