From 46c0cc6a125bca8ffcc944a0ff8ac3347ed91d20 Mon Sep 17 00:00:00 2001 From: Jonas 'Sortie' Termansen Date: Tue, 22 Nov 2011 22:08:34 +0100 Subject: [PATCH] -1 is no longer an allowed system call. This treats a nasty bug where forking and exiting before the child causes the kernel to panic, because the syscall -1 is run, which just contains a trash value that happened to be 0. The cause is still unknown. Might be the scheduler. This won't help me sleep at night. --- sortix/x86/syscall.s | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sortix/x86/syscall.s b/sortix/x86/syscall.s index 47e75498..87b7ad4f 100644 --- a/sortix/x86/syscall.s +++ b/sortix/x86/syscall.s @@ -63,7 +63,7 @@ syscall_handler: # Make sure the requested system call is valid. cmp SYSCALL_MAX, %eax - jl valid_eax + jb valid_eax xorl %eax, %eax valid_eax: