mirror of
https://github.com/Fennix-Project/Kernel.git
synced 2025-05-28 15:34:33 +00:00
Check if the thread pointer is valid before accessing it's data
This commit is contained in:
parent
71c9306828
commit
d472fddb61
@ -167,8 +167,9 @@ namespace Tasking
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
foreach (TCB *thread in Process->Threads)
|
foreach (TCB *thread in Process->Threads)
|
||||||
if (thread->Status == Terminated)
|
if (!InvalidTCB(thread))
|
||||||
RemoveThread(thread);
|
if (thread->Status == Terminated)
|
||||||
|
RemoveThread(thread);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user