Trivial binfmt logic clean-up

This commit is contained in:
Gregory Nutt 2014-11-14 10:38:58 -06:00
parent 66dbce8cf6
commit bd1b5094b4
1 changed files with 1 additions and 3 deletions

View File

@ -124,8 +124,6 @@ static inline int binfmt_copyargv(FAR struct binary_s *bin, FAR char * const *ar
/* Allocate the argv array and an argument buffer */
i = 0;
if (argsize > 0)
{
argvsize = (nargs + 1) * sizeof(FAR char *);
@ -140,7 +138,7 @@ static inline int binfmt_copyargv(FAR struct binary_s *bin, FAR char * const *ar
bin->argv = (FAR char **)bin->argbuffer;
ptr = bin->argbuffer + argvsize;
for (; argv[i]; i++)
for (i = 0; argv[i]; i++)
{
bin->argv[i] = ptr;
argsize = strlen(argv[i]) + 1;