* lib/glob.c (glob): Port recent patches to platforms
lacking getpwnam_r.
2017-09-02 Paul Eggert <eggert@cs.ucla.edu>
+ glob: don't assume getpwnam_r
+ * lib/glob.c (glob): Port recent patches to platforms
+ lacking getpwnam_r.
+
scratch_buffer: don’t use private glibc API
Suggested by Florian Weimer in:
http://lists.gnu.org/archive/html/bug-gnulib/2017-09/msg00004.html
if (success)
{
struct passwd *p;
-# if defined HAVE_GETPWNAM_R || defined _LIBC
- struct passwd pwbuf;
int save = errno;
struct scratch_buffer pwtmpbuf;
scratch_buffer_init (&pwtmpbuf);
+# if defined HAVE_GETPWNAM_R || defined _LIBC
+ struct passwd pwbuf;
while (getpwnam_r (name, &pwbuf,
pwtmpbuf.data, pwtmpbuf.length, &p)