Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Crash of 4.2.0-dev-1
- X-seq: zsh-workers 19784
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxx
- Subject: Re: Crash of 4.2.0-dev-1
- Date: Fri, 16 Apr 2004 04:06:53 +0000
- In-reply-to: <11620.1082052793@xxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
- References: <11620.1082052793@xxxxxxx>
On Apr 15, 7:13pm, Peter Stephenson wrote:
> >
> > zsh: kshtest: function not defined by file
>
> This must be from the EF_RUN test in doshfunc, right?
I wasn't sure, but I just tried setting breakpoints on both places and
that's the one it hit.
> That means you see the message just after the outer kshtest is run,
> I think.
Right, except that there is no "inner" definition of kshtest in this
case -- there's an "inner" *call*:
zagzig% autoload +X -k kshtest
zagzig% functions kshtest
kshtest () {
print "Running kshtest"
unfunction kshtest
kshtest "$@"
}
zagzig% kshtest
Running kshtest
zsh: kshtest: function not defined by file
> I believe (but haven't checked) we always duplicate a function to
> execute so that it's safe to unfunction while it's being executed.
> Could that be failing here?
Yes, that's what I think is happening. It may be of interest to note
that the `kshtest "$@"' line either never executes, or does so without
producing any output or errors of any kind. (I would have at least
expected it to say "command not found".) There's no second call to
exec.c:loadautofn() which I at first suspected might be the reason for
the crash. (The first call to loadautofn() is from `autoload -X'.)
Or at least the above is what happens when I run it in the debugger.
I suppose something different might be happening when not debugging.
Oliver's patch in 19767 doesn't seem to make any difference to this,
not that I expected it to.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author