mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 11:38:11 +00:00
Kernel+LibC: Remove the isatty() syscall
This can be implemented entirely in userspace by calling tcgetattr(). To avoid screwing up the syscall indexes, this patch also adds a mechanism for removing a syscall without shifting the index of other syscalls. Note that ports will still have to be rebuilt after this change, as their LibC code will try to make the isatty() syscall on startup.
This commit is contained in:
parent
3d558f47b0
commit
3da6d89d1f
6 changed files with 19 additions and 14 deletions
|
@ -48,11 +48,13 @@ void initialize()
|
|||
|
||||
#pragma GCC diagnostic ignored "-Wcast-function-type"
|
||||
typedef int (Process::*Handler)(u32, u32, u32);
|
||||
#define __ENUMERATE_REMOVED_SYSCALL(x) nullptr,
|
||||
#define __ENUMERATE_SYSCALL(x) reinterpret_cast<Handler>(&Process::sys$##x),
|
||||
static Handler s_syscall_table[] = {
|
||||
ENUMERATE_SYSCALLS
|
||||
};
|
||||
#undef __ENUMERATE_SYSCALL
|
||||
#undef __ENUMERATE_REMOVED_SYSCALL
|
||||
|
||||
int handle(RegisterDump& regs, u32 function, u32 arg1, u32 arg2, u32 arg3)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue