[prev in list] [next in list] [prev in thread] [next in thread] 

List:       busybox-cvs
Subject:    [git commit master 1/1] init: fix a case where execv's 1st arg was wrong
From:       vda.linux () googlemail ! com (Denys Vlasenko)
Date:       2011-03-21 4:07:43
Message-ID: 20110321040820.9E7F98186D () busybox ! osuosl ! org
[Download RAW message or body]


commit: http://git.busybox.net/busybox/commit/?id=32176ccec4eb1a3bc26b0217fa8d23f6ff44fab8
branch: http://git.busybox.net/busybox/commit/?id=refs/heads/master

Signed-off-by: Denys Vlasenko <vda.linux at googlemail.com>
---
 init/init.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/init/init.c b/init/init.c
index 586e34a..ff9dc06 100644
--- a/init/init.c
+++ b/init/init.c
@@ -414,6 +414,7 @@ static void init_exec(const char *command)
 		char *word, *next;
 		int i = 0;
 		next = strcpy(buf, command - dash); /* command including "-" */
+		command = next + dash;
 		while ((word = strsep(&next, " \t")) != NULL) {
 			if (*word != '\0') { /* not two spaces/tabs together? */
 				cmd[i] = word;
-- 
1.7.3.4


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic