file: fd_allocate

This commit is contained in:
Matheus
2023-05-13 21:12:25 -03:00
parent 18bea63d1c
commit d8cb7b2f42
2 changed files with 5 additions and 0 deletions
+4
View File
@@ -38,6 +38,10 @@ static void cleanfile(file_t *file) {
slab_free(filecache, file);
}
file_t *fd_allocate() {
return newfile();
}
file_t *fd_get(int fd) {
proc_t *proc = _cpu()->thread->proc;
bool intstatus = interrupt_set(false);