Setenv/putenv changes break existing code.
Ulrich Drepper
drepper@cygnus.com
Mon Aug 2 18:40:00 GMT 1999
hjl@lucon.org (H.J. Lu) writes:
> [...] In either case, the string pointed to
> by string becomes part of the environment, so altering the string will
> change the environment. The space used by string is no longer used
> once a new string-defining name is passed to putenv().
>
> It seems to me that it is ok to free 'p' since it is no longer used
> when returning from putenv ().
You are quoting the standard and still don't see that your argument is
wrong? The putenv() code as it is now is correct.
--
---------------. drepper at gnu.org ,-. 1325 Chesapeake Terrace
Ulrich Drepper \ ,-------------------' \ Sunnyvale, CA 94089 USA
Cygnus Solutions `--' drepper at cygnus.com `------------------------
More information about the Libc-hacker
mailing list