diff options
Diffstat (limited to 'man3/putenv.3')
-rw-r--r-- | man3/putenv.3 | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/man3/putenv.3 b/man3/putenv.3 index 9f4db0155..da15b2eff 100644 --- a/man3/putenv.3 +++ b/man3/putenv.3 @@ -14,7 +14,7 @@ .\" Modified Mon Oct 11 11:11:11 1999 by Andries Brouwer (aeb@cwi.nl) .\" Modified Wed Nov 10 00:02:26 1999 by Andries Brouwer (aeb@cwi.nl) .\" Modified Sun May 20 22:17:20 2001 by Andries Brouwer (aeb@cwi.nl) -.TH putenv 3 2023-02-05 "Linux man-pages 6.03" +.TH putenv 3 2023-07-20 "Linux man-pages 6.05.01" .SH NAME putenv \- change or add an environment variable .SH LIBRARY @@ -66,23 +66,23 @@ Insufficient space to allocate new environment. .SH ATTRIBUTES For an explanation of the terms used in this section, see .BR attributes (7). -.ad l -.nh .TS allbox; lbx lb lb l l l. Interface Attribute Value T{ +.na +.nh .BR putenv () T} Thread safety MT-Unsafe const:env .TE -.hy -.ad .sp 1 .SH STANDARDS -POSIX.1-2001, POSIX.1-2008, SVr4, 4.3BSD. -.SH NOTES +POSIX.1-2008. +.SH HISTORY +POSIX.1-2001, SVr2, 4.3BSD-Reno. +.PP The .BR putenv () function is not required to be reentrant, and the @@ -112,12 +112,13 @@ changing it later will change the environment. with an automatic variable as the argument, then return from the calling function while \fIstring\fP is still part of the environment.) -However, from glibc 2.0 to glibc 2.1.1, it differs:r +However, from glibc 2.0 to glibc 2.1.1, it differs: a copy of the string is used. On the one hand this causes a memory leak, and on the other hand it violates SUSv2. .PP -The 4.4BSD version, like glibc 2.0, uses a copy. +The 4.3BSD-Reno version, like glibc 2.0, uses a copy; +this is fixed in all modern BSDs. .PP SUSv2 removes the \fIconst\fP from the prototype, and so does glibc 2.1.3. .PP |