* zsh as sh hates `unset CDPATH'
@ 1998-05-14 20:10 SL Baur
1998-05-15 4:39 ` PATCH: " Zoltan Hidvegi
0 siblings, 1 reply; 3+ messages in thread
From: SL Baur @ 1998-05-14 20:10 UTC (permalink / raw)
To: zsh-workers
(Apologies if this is fixed in the 3.1.3 beta which I just found out
about moments ago. Thanks for a wonderful shell, I've been running 3.1.2
as /bin/sh for some months now).
I've verified the existence of this bug in 3.1.2, 3.0.5, 3.0.4, and
2.6beta20 on various flavors of Linux libc5 and GNU libc.
Repeat by:
zsh$ cd /tmp
zsh$ ln -s /bin/zsh ./sh
zsh$ ./sh
sh$ unset CDPATH
zsh: 20286 segmentation fault ./sh
zsh$
^ permalink raw reply [flat|nested] 3+ messages in thread
* PATCH: Re: zsh as sh hates `unset CDPATH'
1998-05-14 20:10 zsh as sh hates `unset CDPATH' SL Baur
@ 1998-05-15 4:39 ` Zoltan Hidvegi
1998-05-15 6:00 ` SL Baur
0 siblings, 1 reply; 3+ messages in thread
From: Zoltan Hidvegi @ 1998-05-15 4:39 UTC (permalink / raw)
To: SL Baur; +Cc: zsh-workers
> zsh$ cd /tmp
> zsh$ ln -s /bin/zsh ./sh
> zsh$ ./sh
> sh$ unset CDPATH
> zsh: 20286 segmentation fault ./sh
> zsh$
The patch below fixes this on 3.1.3. It to patch 3.0.5, edit the patch
and remore the exp argument from unsetparm_pm (you have to remove it in
both side of the path), so that it looks like unserparm_pm(altpm, 1);
Zoli
*** Src/params.c.orig Fri May 8 00:42:56 1998
--- Src/params.c Thu May 14 23:34:53 1998
*************** unsetparam_pm(Param pm, int altflag, int
*** 1335,1341 ****
/* remove it under its alternate name if necessary */
if (pm->ename && !altflag) {
altpm = (Param) paramtab->getnode(paramtab, pm->ename);
! unsetparam_pm(altpm, 1, exp);
}
if (locallevel >= pm->level && (pm->flags & PM_SPECIAL))
--- 1335,1342 ----
/* remove it under its alternate name if necessary */
if (pm->ename && !altflag) {
altpm = (Param) paramtab->getnode(paramtab, pm->ename);
! if (altpm)
! unsetparam_pm(altpm, 1, exp);
}
if (locallevel >= pm->level && (pm->flags & PM_SPECIAL))
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: PATCH: Re: zsh as sh hates `unset CDPATH'
1998-05-15 4:39 ` PATCH: " Zoltan Hidvegi
@ 1998-05-15 6:00 ` SL Baur
0 siblings, 0 replies; 3+ messages in thread
From: SL Baur @ 1998-05-15 6:00 UTC (permalink / raw)
To: Zoltan Hidvegi; +Cc: zsh-workers
Zoltan Hidvegi <hzoli@cs.elte.hu> writes:
> The patch below fixes this on 3.1.3. ...
It works great. Thank you.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~1998-05-15 6:01 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1998-05-14 20:10 zsh as sh hates `unset CDPATH' SL Baur
1998-05-15 4:39 ` PATCH: " Zoltan Hidvegi
1998-05-15 6:00 ` SL Baur
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).