mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-29 04:37:55 +00:00
Kernel: Strongly typed user & group ID's
Prior to this change, both uid_t and gid_t were typedef'ed to `u32`. This made it easy to use them interchangeably. Let's not allow that. This patch adds UserID and GroupID using the AK::DistinctNumeric mechanism we've already been employing for pid_t/ProcessID.
This commit is contained in:
@@ -344,7 +344,7 @@ void init_stage2(void*)
|
||||
RefPtr<Thread> thread;
|
||||
auto userspace_init = kernel_command_line().userspace_init();
|
||||
auto init_args = kernel_command_line().userspace_init_args();
|
||||
Process::create_user_process(thread, userspace_init, (uid_t)0, (gid_t)0, ProcessID(0), error, move(init_args), {}, tty0);
|
||||
Process::create_user_process(thread, userspace_init, UserID(0), GroupID(0), ProcessID(0), error, move(init_args), {}, tty0);
|
||||
if (error != 0) {
|
||||
PANIC("init_stage2: Error spawning SystemServer: {}", error);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user