aboutsummaryrefslogtreecommitdiff
path: root/kernel/features/syscall.c
diff options
context:
space:
mode:
authorMarvin Borner2020-08-22 00:35:27 +0200
committerMarvin Borner2020-08-22 00:35:27 +0200
commite72ef04668a87702c92cebc868612b9ebb8b0ad8 (patch)
treee100829c5a14f2135906d9abafbf9767f4fc6ee7 /kernel/features/syscall.c
parent94de27efb7f9f97d162c1cd6b0a2bb89e3fe555f (diff)
Switched proc linked list to libc list
Diffstat (limited to 'kernel/features/syscall.c')
-rw-r--r--kernel/features/syscall.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/features/syscall.c b/kernel/features/syscall.c
index ac79fc1..2704690 100644
--- a/kernel/features/syscall.c
+++ b/kernel/features/syscall.c
@@ -58,12 +58,12 @@ void syscall_handler(struct regs *r)
((u32 *)proc->regs.useresp)[0] = argc;
((u32 *)proc->regs.useresp)[1] = (u32)argv;
if (r->eax)
- proc->state = PROC_ERROR;
+ proc_exit(proc, r->eax);
break;
}
case SYS_EXIT: {
printf("exit\n");
- proc_exit(r->ebx);
+ proc_exit(proc_current(), r->ebx);
break;
}
case SYS_MAP: {