summaryrefslogtreecommitdiff
path: root/src/kernel/vfs
diff options
context:
space:
mode:
Diffstat (limited to 'src/kernel/vfs')
-rw-r--r--src/kernel/vfs/node.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/kernel/vfs/node.cpp b/src/kernel/vfs/node.cpp
index c517aae..0b753af 100644
--- a/src/kernel/vfs/node.cpp
+++ b/src/kernel/vfs/node.cpp
@@ -54,6 +54,7 @@ node* vfs_find(node* root, char* fn) {
}
node* vfs_read_fd(FILE d) {
+ if (d < 0) return 0;
return current_process->fd.at(d);
}