zsh-workers
 help / color / mirror / code / Atom feed
From: Zoltan Hidvegi <hzoli@cs.elte.hu>
To: gene@sapience.com (Gene Cohler)
Cc: zsh-workers@math.gatech.edu (zsh-workers)
Subject: Re: hzoli13 another bug ?
Date: Mon, 25 Mar 1996 13:50:44 +0100 (MET)	[thread overview]
Message-ID: <199603251250.NAA01730@bolyai.cs.elte.hu> (raw)
In-Reply-To: <9603242016.ZM20938@cogent.sapience.com> from Gene Cohler at "Mar 24, 96 08:16:46 pm"

> 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);



       reply	other threads:[~1996-03-25 13:03 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <9603242016.ZM20938@cogent.sapience.com>
1996-03-25 12:50 ` Zoltan Hidvegi [this message]
1996-03-26  0:02   ` Zoltan Hidvegi

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=199603251250.NAA01730@bolyai.cs.elte.hu \
    --to=hzoli@cs.elte.hu \
    --cc=gene@sapience.com \
    --cc=zsh-workers@math.gatech.edu \
    /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).