mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-11 18:20:43 +09:00
Kernel: Make Threads always have a name
We previously allowed Thread to exist in a state where its m_name was null, and had to work around that in various places. This patch removes that possibility and forces those who would create a thread (or change the name of one) to provide a NonnullOwnPtr<KString> with the name.
This commit is contained in:
parent
cda2b9e71c
commit
7981422500
Notes:
sideshowbarker
2024-07-18 04:37:13 +09:00
Author: https://github.com/awesomekling
Commit: 7981422500
7 changed files with 25 additions and 13 deletions
|
@ -739,7 +739,7 @@ KResult Process::send_signal(u8 signal, Process* sender)
|
|||
return ESRCH;
|
||||
}
|
||||
|
||||
RefPtr<Thread> Process::create_kernel_thread(void (*entry)(void*), void* entry_data, u32 priority, OwnPtr<KString> name, u32 affinity, bool joinable)
|
||||
RefPtr<Thread> Process::create_kernel_thread(void (*entry)(void*), void* entry_data, u32 priority, NonnullOwnPtr<KString> name, u32 affinity, bool joinable)
|
||||
{
|
||||
VERIFY((priority >= THREAD_PRIORITY_MIN) && (priority <= THREAD_PRIORITY_MAX));
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue