This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
There is a mistake in the manual of GNU libc.
- From: "Takashi Nishiie" <t-nishiie at soft dot fujitsu dot com>
- To: <libc-alpha at sources dot redhat dot com>
- Date: Wed, 29 Aug 2007 15:25:27 +0900
- Subject: There is a mistake in the manual of GNU libc.
Hi,
There is a mistake in the manual of libc.
Ulrich Drepper said:
---
http://sourceware.org/bugzilla/show_bug.cgi?id=4887
setenv, putenv, clearenve, etc are not allowed in threaded
code without killing the rest.
---
The manual of GNU libc has the following description.
---
http://www.gnu.org/software/libc/manual/html_mono/libc.html#Environment-Access
25.4.1 Environment Access
The value of an environment variable can be accessed with
the getenv function. This is declared in the header file
stdlib.h. All of the following functions can be safely used
in multi-threaded programs. It is made sure that concurrent
modifications to the environment do not lead to errors.
char * getenv (const char *name)
...
int putenv (char *string)
...
int setenv (const char *name, const char *value, int replace)
...
int unsetenv (const char *name)
---
If description of a manual is right, functions, such as
setenv(), putenv(), and clearenv(), are corrected to thread-safe.
You should correct description of the manual, if that is not right.
Thanks.