zsh-workers
 help / color / mirror / code / Atom feed
From: "Sean C. Farley" <scf@FreeBSD.org>
To: Peter Stephenson <p.w.stephenson@ntlworld.com>
Cc: "Sean C. Farley" <scf@FreeBSD.org>, zsh-workers@sunsite.dk
Subject: Re: putenv()/environ bug
Date: Mon, 30 Jul 2007 17:44:12 -0500 (CDT)	[thread overview]
Message-ID: <20070730173959.B5687@thor.farley.org> (raw)
In-Reply-To: <20070730215232.ff040a3f.p.w.stephenson@ntlworld.com>

On Mon, 30 Jul 2007, Peter Stephenson wrote:

> Paranoia.
>
> Index: Test/B02typeset.ztst
> ===================================================================
> RCS file: /cvsroot/zsh/zsh/Test/B02typeset.ztst,v
> retrieving revision 1.13
> diff -u -r1.13 B02typeset.ztst
> --- Test/B02typeset.ztst	28 May 2007 22:57:42 -0000	1.13
> +++ Test/B02typeset.ztst	30 Jul 2007 20:52:56 -0000
> @@ -377,3 +377,14 @@
> >integer local i
> >local tagged scalar
> >preserved
> +
> + export ENVFOO=bar
> + print ENVFOO in environment
> + env | grep '^ENVFOO'
> + unset ENVFOO
> + print ENVFOO no longer in environment
> + env | grep '^ENVFOO'
> +1:Adding and removing values to and from the environment
> +>ENVFOO in environment
> +>ENVFOO=bar
> +>ENVFOO no longer in environment

This test would work even before the patch.  The issue only showed up if
zsh was executed again.

Example:
zsh
export FOO=BAR
exec zsh
unset FOO
env | grep FOO
echo $FOO

Sean
-- 
scf@FreeBSD.org


  reply	other threads:[~2007-07-30 22:44 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-07-25 15:09 Sean C. Farley
2007-07-25 20:53 ` Peter Stephenson
2007-07-26  0:14   ` Sean C. Farley
2007-07-28 18:46     ` Andrey Borzenkov
2007-07-29 19:08       ` Sean C. Farley
2007-07-30 20:39         ` Peter Stephenson
2007-07-30 20:52           ` Peter Stephenson
2007-07-30 22:44             ` Sean C. Farley [this message]
2007-07-31  9:00               ` Peter Stephenson
2007-07-31 18:09                 ` Sean C. Farley
2007-07-30 22:39           ` Sean C. Farley

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=20070730173959.B5687@thor.farley.org \
    --to=scf@freebsd.org \
    --cc=p.w.stephenson@ntlworld.com \
    --cc=zsh-workers@sunsite.dk \
    /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).