[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: env -u behavior
From: |
Eric Blake |
Subject: |
Re: env -u behavior |
Date: |
Fri, 23 Oct 2009 20:33:01 +0000 (UTC) |
User-agent: |
Loom/3.14 (http://gmane.org/) |
Eric Blake <ebb9 <at> byu.net> writes:
> Is 'env -i -u a=b' really supposed to output a=b, or should it be an error
> (because a=b is not a valid environment name)? Right now, it is the former,
> because we are using putenv() to remove variables from environ, rather than
> unsetenv(). Similarly, should env -u '' issue an error?
Also, if I'm reading POSIX correctly,
env -- a=b true
is supposed to execute true with a=b in the environment, rather than GNU
behavior of executing ./a=b (POSIX says to use 'env ./a=b true' to get similar
behavior). But POSIX and GNU at least agree that:
env -- -i a=b
executes ./-i a=b, rather than printing "a=b".
Do we go ahead and call this a bug, and fix it? Or is it obscure enough to
wrap in POSIXLY_CORRECT?
--
Eric Blake
- env -u behavior, Eric Blake, 2009/10/23
- Re: env -u behavior,
Eric Blake <=
- Re: env -u behavior, Mike Frysinger, 2009/10/24
- Re: env -u behavior, Eric Blake, 2009/10/24
- Re: env -u behavior, Mike Frysinger, 2009/10/25
- Re: env -u behavior, Eric Blake, 2009/10/26
- Re: env -u behavior, Mike Frysinger, 2009/10/26
- Re: env -u behavior, Eric Blake, 2009/10/26
- Re: env -u behavior, Jim Meyering, 2009/10/26