Fix some compile errors introduce in last commits
This commit is contained in:
parent
bc265d74e7
commit
838f2053e4
@ -40,7 +40,9 @@
|
||||
#include <nuttx/config.h>
|
||||
|
||||
#include <stdarg.h>
|
||||
#include <stdlib.h>
|
||||
#include <unistd.h>
|
||||
#include <errno.h>
|
||||
|
||||
#ifdef CONFIG_LIBC_EXECFUNCS
|
||||
|
||||
@ -155,7 +157,7 @@ int execl(FAR const char *path, ...)
|
||||
if (nargs > 0)
|
||||
{
|
||||
argv = (FAR char **)malloc((nargs + 1) * sizeof(FAR char *));
|
||||
if (argv = (FAR char **)NULL)
|
||||
if (argv == (FAR char **)NULL)
|
||||
{
|
||||
set_errno(ENOMEM);
|
||||
return ERROR;
|
||||
|
@ -496,7 +496,7 @@ static inline int task_stackargsetup(FAR struct task_tcb_s *tcb,
|
||||
*/
|
||||
|
||||
strtablen += (strlen(argv[argc]) + 1);
|
||||
if (strtablen >= tcb->adj_stack_size)
|
||||
if (strtablen >= tcb->cmn.adj_stack_size)
|
||||
{
|
||||
return -ENAMETOOLONG;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user