hush in arm nommu environment
Denis Vlasenko
vda.linux at googlemail.com
Mon Aug 6 07:10:25 PDT 2007
On Monday 06 August 2007 09:21, Per Hallsmark wrote:
> Hi all,
>
> I've tried out the hush shell in busybox 1.6.1.
> Seems to work fairly well with the patch last in
> this mail.
...
> --- busybox-1.6.1.orig/shell/hush.c 2007-06-30 17:06:37.000000000 +0200
> +++ busybox-1.6.1/shell/hush.c 2007-08-02 15:41:22.000000000 +0200
> @@ -658,7 +658,11 @@
> pid_t pid;
>
> debug_printf_jobs("got tty sig %d in pid %d\n", sig, getpid());
> +#if BB_MMU
> pid = fork();
> +#else
> + pid = vfork();
> +#endif
> if (pid < 0) /* can't fork. Pretend there was no ctrl-Z */
> return;
> ctrl_z_flag = 1;
I'm afraid this maybe works for some simple scripts, but I'm sure as hell
there are nasty bugs. Code does assume that after fork() we create
new process. Simply replacing it with vfork is not going to work stably.
--
vda
More information about the busybox
mailing list