This is the mail archive of the
cygwin@sources.redhat.com
mailing list for the Cygwin project.
RE: putenv() - copying environment string violates Unix specs?
- To: "cygwin" <cygwin at sources dot redhat dot com>
- Subject: RE: putenv() - copying environment string violates Unix specs?
- From: "Andrej Borsenkow" <Andrej dot Borsenkow at mow dot siemens dot ru>
- Date: Tue, 25 Jul 2000 16:07:19 +0400
> > Of course, then setenv() should never attempt to reuse old
> environment
> > string. Just occured to me. That gives consitent handling -
> caller is
> > responsible for allocating and freeing environment strings.
>
> That's not required by SUSv2. If you call setenv you can't
> influence memory usage in any way. See the glibc example.
>
Granted. That implies, that mixing putenv() and setenv() is a bad thing.
Good to know :-)
-andrej
--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com