Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: zsh behavior when fork() failed
- X-seq: zsh-workers 30321
- From: Dipak Gaigole <dipakgaigole@xxxxxxxxx>
- To: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- Subject: Re: zsh behavior when fork() failed
- Date: Tue, 6 Mar 2012 14:31:24 +0530
- Authentication-results: mr.google.com; spf=pass (google.com: domain of dipakgaigole@xxxxxxxxx designates 10.112.8.129 as permitted sender) smtp.mail=dipakgaigole@xxxxxxxxx; dkim=pass header.i=dipakgaigole@xxxxxxxxx
- Cc: zsh-workers@xxxxxxx
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; bh=CiUXu89JTN++au3JKPp769VkUVESjgFdAHDRzm2rAvo=; b=QPiDxm3NeFEarm6+AMs+7qKtaJmlz0oveXGx5NexqyQ5OirA5tsclH0k5fYv7sqO/F BmIiJFrAkm8hbwg0m0uvyG3ZbXOckf06+GvAIakP4ZWAW69nW4YUZvKN5bMlJw0cVO7U Ju9Y5l4kbLHuzN3fhquzheCaqDHmVzi4QMPeHYPYUfOZZIDOPqRAONTY3tBfAD5KqQCr UmMYNQHjKoPX7CSQfV4IvA0HhSKEBamvuumjMqwdlUyr7mnk52G9C3oEHD+WK82qrUME zEfUN9JdIdmxG7plJ13PffowlCLXZ+cu8B+5fFOzvu12OAQFVB3ou/8fpltf/3boyk5u RPMQ==
- In-reply-to: <120229110632.ZM28317@torch.brasslantern.com>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <CADs2-=SFXA0rt1tKvBTnJC=UGdeaQk_GhSp_xM9EGFi_RW_YxA@mail.gmail.com> <120223081441.ZM2715@torch.brasslantern.com> <CADs2-=Qz7RaX_ntVupWo=rk+-cKj45-i1K=rhm9p6Apw-xa5sQ@mail.gmail.com> <120224100518.ZM13322@torch.brasslantern.com> <CADs2-=RNMAHz=fQOWjVm25XRL4xaGLzTtA7yL-FCQPrHdV5jpg@mail.gmail.com> <120226115220.ZM17815@torch.brasslantern.com> <CADs2-=Qb4o9gh_40ASr8HNGfpSz8XLEcy0pqQLnJC+eE6ZvRSg@mail.gmail.com> <120229110632.ZM28317@torch.brasslantern.com>
On Thu, Mar 1, 2012 at 12:36 AM, Bart Schaefer
<schaefer@xxxxxxxxxxxxxxxx> wrote:
> On Feb 29, 6:27pm, Dipak Gaigole wrote:
> }
> } I have applied this patch but unfortunately the script still continues
> } even after the fork failures while executing commands from the script.
> }
> } bash-2.05b$ cat /tmp/test1.sh
> } #!/bin/sh
> } x="My default value"
> } x=`date`
> } echo $?
> } echo "Current Date is:" "$x"
> } date
> } echo $?
> } bash-2.05b$ zsh /tmp/test1.sh
> } /tmp/test1.sh:3: fork failed: resource temporarily unavailable
> } 1
> } Current Date is: My default value
> } /tmp/test1.sh:6: fork failed: resource temporarily unavailable
> } 1
> } bash-2.05b$
> }
> } Can you please check this on your end?
>
> I get (schaefer[N] is my top-level prompt):
>
> schaefer[691] Src/zsh -f /tmp/test1.sh
> /tmp/test1.sh:3: fork failed: resource temporarily unavailable
> 1
> Current Date is: My default value
> /tmp/test1.sh:6: fork failed: resource temporarily unavailable
> schaefer[692] echo $?
> 1
>
> There's no exit after `date` because that was in a subshell, but I do
> see the exit after the command in the parent shell.
>
> Are you sure a path-searched "zsh" is finding the right binary?
Sorry my bad :( I had missed one of the fatal condition.
Thanks for your help Bart !!!
-Dipak
Messages sorted by:
Reverse Date,
Date,
Thread,
Author