* Re: hzoli13 another bug ?
[not found] <9603242016.ZM20938@cogent.sapience.com>
@ 1996-03-25 12:50 ` Zoltan Hidvegi
1996-03-26 0:02 ` Zoltan Hidvegi
0 siblings, 1 reply; 2+ messages in thread
From: Zoltan Hidvegi @ 1996-03-25 12:50 UTC (permalink / raw)
To: Gene Cohler; +Cc: zsh-workers
> Hey Zoltan:
>
> I have run into another problem.
>
> After assigning result code of execution to a variable it has wrong value:
>
> % egrep -q $u $DbFile
> % echo $?
> 1
> % egrep -q $u $DbFile
> % rc=$?
> % echo $rc
> 0
>
> Again this is not in the stock beta13 version.
A patch in art. 637 from Zefram broke this. It tried to fix a bug when an
assignment like wibble=$(false) did not set $?. Everyone who applied the
patch in art. 637 (i.e. everyone using beta13-hzoli13) should also apply
the patch below.
Bye,
Zoltan
*** Src/exec.c 1996/03/22 21:33:31 1.15
--- Src/exec.c 1996/03/25 12:41:37
***************
*** 1174,1182 ****
} else
addlinknode(args, dupstring(nullcmd));
} else {
- lastval = 0;
addvars(cmd->vars, 0);
! if(errflag) lastval = errflag;
if (isset(XTRACE)) {
fputc('\n', stderr);
fflush(stderr);
--- 1174,1184 ----
} else
addlinknode(args, dupstring(nullcmd));
} else {
addvars(cmd->vars, 0);
! if(errflag)
! lastval = errflag;
! else
! lastval = 0;
if (isset(XTRACE)) {
fputc('\n', stderr);
fflush(stderr);
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: hzoli13 another bug ?
1996-03-25 12:50 ` hzoli13 another bug ? Zoltan Hidvegi
@ 1996-03-26 0:02 ` Zoltan Hidvegi
0 siblings, 0 replies; 2+ messages in thread
From: Zoltan Hidvegi @ 1996-03-26 0:02 UTC (permalink / raw)
To: Zoltan Hidvegi
[-- Attachment #1: Type: application/pgp, Size: 1885 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~1996-03-26 0:17 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <9603242016.ZM20938@cogent.sapience.com>
1996-03-25 12:50 ` hzoli13 another bug ? Zoltan Hidvegi
1996-03-26 0:02 ` Zoltan Hidvegi
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).