nommu: fix cases where we mangle argv[0][0]

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
Denys Vlasenko
2011-11-22 17:19:26 +01:00
parent fcb9e07eca
commit d2277e262f
4 changed files with 7 additions and 0 deletions

View File

@@ -2243,6 +2243,7 @@ static void mini_httpd_nommu(int server_socket, int argc, char **argv)
/* Run a copy of ourself in inetd mode */
re_exec(argv_copy);
}
argv_copy[0][0] &= 0x7f;
/* parent, or vfork failed */
close(n);
} /* while (1) */