mirror of
https://github.com/RT-Thread/rt-thread.git
synced 2025-12-27 01:28:23 +00:00
[smart] split out part of lwp_new() to lwp_create()
Prev implementation of lwp_new() including the create of lwp object and the pid allocation. But not every lwp object need a pid. So this patch split out the business of lwp_new() to improve the maintainability. Signed-off-by: Shell <smokewood@qq.com>
This commit is contained in:
@@ -1152,7 +1152,7 @@ pid_t lwp_execve(char *filename, int debug, int argc, char **argv, char **envp)
|
||||
return -EACCES;
|
||||
}
|
||||
|
||||
lwp = lwp_new();
|
||||
lwp = lwp_create(LWP_CREATE_FLAG_ALLOC_PID);
|
||||
|
||||
if (lwp == RT_NULL)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user