1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 07:48:11 +00:00

Kernel+LibC: Add get_process_name() syscall

It does exactly what it sounds like:

    int get_process_name(char* buffer, int buffer_size);
This commit is contained in:
Andreas Kling 2019-08-15 20:55:10 +02:00
parent d64e698bf1
commit 6ad3efe067
6 changed files with 29 additions and 1 deletions

View file

@ -307,6 +307,8 @@ static u32 handle(RegisterDump& regs, u32 function, u32 arg1, u32 arg2, u32 arg3
return current->process().sys$set_process_icon((int)arg1);
case Syscall::SC_mprotect:
return current->process().sys$mprotect((void*)arg1, (size_t)arg2, (int)arg3);
case Syscall::SC_get_process_name:
return current->process().sys$get_process_name((char*)arg1, (int)arg2);
default:
kprintf("<%u> int0x82: Unknown function %u requested {%x, %x, %x}\n", current->process().pid(), function, arg1, arg2, arg3);
return -ENOSYS;