Re: setenv memory leak fix (take 3)

From: Sean C. Farley <sean-freebsd_at_farley.org>
Date: Mon, 30 Apr 2007 21:04:46 -0500 (CDT)
On Fri, 27 Apr 2007, Andrey Chernov wrote:

> On Thu, Apr 26, 2007 at 08:10:29PM -0500, Sean C. Farley wrote:
>>  Are there any opinions on having unsetenv() return a value to match
>>  unsetenv() in IEEE Std 1003.1?
>
> There is no much options because we should conform to standards and
> unsetenv() should return int therefore.

I know that unsetenv() can be changed without problems since it has no
return value at the moment.  The others are more difficult but not
impossible.  I see that a mild discussion has occurred on cvs.  :)

Here are both scenarios with my code changes:
BSD[1] (only unsetenv() is updated to return an int.  Easy to change
         back)
POSIX[2] (all *env() functions are updated to reflect POSIX)

Sean
   1. http://www.farley.org/freebsd/tmp/setenv-8/BSD/sysenv.c
   2. http://www.farley.org/freebsd/tmp/setenv-8/POSIX/sysenv.c
-- 
sean-freebsd_at_farley.org
Received on Tue May 01 2007 - 00:28:51 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:09 UTC