mirror of
https://github.com/apache/nuttx.git
synced 2026-05-21 21:34:07 +08:00
sched/pthread: fix memory leak of pthread_tcb_s
pthread tcb should be released appropriately Signed-off-by: chao an <anchao@lixiang.com>
This commit is contained in:
@@ -216,6 +216,8 @@ int nx_pthread_create(pthread_trampoline_t trampoline, FAR pthread_t *thread,
|
||||
return ENOMEM;
|
||||
}
|
||||
|
||||
ptcb->cmn.flags |= TCB_FLAG_FREE_TCB;
|
||||
|
||||
/* Bind the parent's group to the new TCB (we have not yet joined the
|
||||
* group).
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user