mirror of
git://sourceware.org/git/glibc.git
synced 2024-11-21 01:12:26 +08:00
[BZ #1061]
2005-07-11 Derek R. Price <derek@ximbiot.com> [BZ #1061] * sysdeps/generic/glob.c (glob): Only a 0 return from getlogin_r means success, according to POSIX 1003.2.
This commit is contained in:
parent
3aeb7ee145
commit
ca85722957
@ -1,4 +1,4 @@
|
||||
/* Copyright (C) 1991-2002, 2003, 2004 Free Software Foundation, Inc.
|
||||
/* Copyright (C) 1991-2002,2003,2004,2005 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
@ -715,7 +715,7 @@ glob (pattern, flags, errfunc, pglob)
|
||||
buflen = 20;
|
||||
name = (char *) __alloca (buflen);
|
||||
|
||||
success = getlogin_r (name, buflen) >= 0;
|
||||
success = getlogin_r (name, buflen) == 0;
|
||||
# else
|
||||
success = (name = getlogin ()) != NULL;
|
||||
# endif
|
||||
|
Loading…
Reference in New Issue
Block a user