summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuillaume Cottenceau <gc@mandriva.com>2001-05-14 14:37:17 +0000
committerGuillaume Cottenceau <gc@mandriva.com>2001-05-14 14:37:17 +0000
commitc0f86abe7a0718da743899a37103b96660b86b15 (patch)
treeb2398ea9ee5b42261b1902cf4db840170414c990
parent881d72fdb098c69a503bfbe5512c6ca049e1ec61 (diff)
downloaddrakx-c0f86abe7a0718da743899a37103b96660b86b15.tar
drakx-c0f86abe7a0718da743899a37103b96660b86b15.tar.gz
drakx-c0f86abe7a0718da743899a37103b96660b86b15.tar.bz2
drakx-c0f86abe7a0718da743899a37103b96660b86b15.tar.xz
drakx-c0f86abe7a0718da743899a37103b96660b86b15.zip
we don't use this sucking sash no more
we now use `busybox' compiled with the marvellous dietlibc, which provides no less than 73 usefull binaries
-rw-r--r--mdk-stage1/stage1.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/mdk-stage1/stage1.c b/mdk-stage1/stage1.c
index 2faa35256..879a9765b 100644
--- a/mdk-stage1/stage1.c
+++ b/mdk-stage1/stage1.c
@@ -81,7 +81,7 @@ static void spawn_shell(void)
{
#ifdef SPAWN_SHELL
int fd;
- char * shell_name = "/sbin/sash";
+ char * shell_name[] = { "/tmp/sh", NULL };
log_message("spawning a shell");
@@ -91,8 +91,8 @@ static void spawn_shell(void)
log_message("cannot open /dev/tty2 -- no shell will be provided");
return;
}
- else if (access(shell_name, X_OK)) {
- log_message("cannot open shell - %s doesn't exist", shell_name);
+ else if (access(shell_name[0], X_OK)) {
+ log_message("cannot open shell - %s doesn't exist", shell_name[0]);
return;
}
@@ -106,8 +106,8 @@ static void spawn_shell(void)
if (ioctl(0, TIOCSCTTY, NULL))
log_perror("could not set new controlling tty");
- execl(shell_name, shell_name, NULL);
- log_message("execl of %s failed: %s", shell_name, strerror(errno));
+ execve(shell_name[0], shell_name, grab_env());
+ log_message("execl of %s failed: %s", shell_name[0], strerror(errno));
}
close(fd);