http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47375
Tobias Burnus <burnus at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |wrong-code CC| |burnus at gcc dot gnu.org --- Comment #1 from Tobias Burnus <burnus at gcc dot gnu.org> 2011-01-20 13:08:43 UTC --- Maybe one should use getpwnam_r and getpwuid_r instead of getpwnam and getpwuid (at least if the _r versions are available); the non-_r versions are used according to http://gcc.gnu.org/onlinedocs/gfortran/GETLOG.html >From POSIX/SUS 2003: " #include <pwd.h> struct passwd *getpwuid(uid_t uid); int getpwuid_r(uid_t uid, struct passwd *pwd, char *buffer, size_t bufsize, struct passwd **result); [...] APPLICATION USAGE [...] The getpwuid_r() function is thread-safe and returns values in a user-supplied buffer instead of possibly using a static data area that may be overwritten by each call."