mirror of
https://github.com/Mathewnd/Astral.git
synced 2026-10-27 12:48:22 +00:00
newthread: fix tid and runningthreadcount
This commit is contained in:
@@ -55,6 +55,11 @@ syscallret_t syscall_newthread(context_t *, void *entry, void *stack) {
|
||||
|
||||
proc->threads[i]->vmmctx = _cpu()->thread->vmmctx;
|
||||
|
||||
ret.errno = 0;
|
||||
ret.ret = proc->threads[i]->tid;
|
||||
|
||||
__atomic_fetch_add(&proc->runningthreadcount, 1, __ATOMIC_SEQ_CST);
|
||||
|
||||
sched_queue(proc->threads[i]);
|
||||
|
||||
cleanup:
|
||||
|
||||
Reference in New Issue
Block a user