From: Han Pingtian <hanpt@linux.vnet.ibm.com>
To: zsh-workers@zsh.org
Subject: Re: Segfault in =( ) substitution
Date: Fri, 21 Dec 2012 17:01:26 +0800 [thread overview]
Message-ID: <20121221090126.GG2464@localhost.localdomain> (raw)
In-Reply-To: <20121221075751.GF2464@localhost.localdomain>
On Fri, Dec 21, 2012 at 03:57:51PM +0800, Han Pingtian wrote:
> On Wed, Oct 17, 2012 at 09:16:03PM +0100, Peter Stephenson wrote:
> > I suppose it's worth pointing out you can now do things like this...
> >
> > () {
> > print File $1:
> > cat $1
> > } =(print This be the verse)
> >
> > producing:
> >
> > File /tmp/zsh0wPl3Y:
> > This be the verse
> >
> > That's a better bet than any hack within the shell that I can think of
> > because the scoping is obvious.
> >
>
> Hello,
>
> I just noticed that this example crashed on zsh both 5.0 and 5.0.1. If I
> compile zsh with debug enabled, it runs like this:
>
> % () {
> function> print File $1:
> function> cat $1
> function> } =(print hello)
> File :
> cat: : No such file or directory
>
> Please take a look. Thanks.
Looks like if revert the below commit this example will work again:
commit ad92cb3203e5d95be91019633e8f1f5835b12794
Author: Peter Stephenson <pws@users.sourceforge.net>
Date: Thu Oct 11 16:36:14 2012 +0000
30724: shell code optimisd to use execsimple() doesn't have a valid
thisjob
diff --git a/ChangeLog b/ChangeLog
index 9768aa8..5a69f01 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2012-10-11 Peter Stephenson <pws@csr.com>
+
+ * 30724: Src/exec.c, Src/jobs.c: shell code optimised to use
+ execsimple() doesn't have a valid thisjob.
+
2012-10-09 Peter Stephenson <pws@csr.com>
... ...
next prev parent reply other threads:[~2012-12-21 9:14 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-10-15 3:30 Vin Shelton
2012-10-15 9:07 ` Peter Stephenson
2012-10-17 19:20 ` Peter Stephenson
2012-10-17 20:16 ` Peter Stephenson
2012-10-18 15:07 ` Bart Schaefer
2012-10-18 15:27 ` Peter Stephenson
2012-12-21 7:57 ` Han Pingtian
2012-12-21 9:01 ` Han Pingtian [this message]
2012-12-21 9:51 ` Han Pingtian
2012-12-21 10:34 ` Peter Stephenson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20121221090126.GG2464@localhost.localdomain \
--to=hanpt@linux.vnet.ibm.com \
--cc=zsh-workers@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).