libandroid-glob: issetugid() not in 64-bit libc

This commit is contained in:
Fredrik Fornwall 2016-01-03 21:24:49 -05:00
parent 9ffcaa63cc
commit 1d7c3a4899
1 changed files with 4 additions and 1 deletions

View File

@ -391,7 +391,10 @@ globtilde(const Char *pattern, Char *patbuf, size_t patbuf_len, glob_t *pglob)
* we're not running setuid or setgid) and then trying
* the password file
*/
if (issetugid() != 0 ||
if (
#ifndef __ANDROID__
issetugid() != 0 ||
#endif
(h = getenv("HOME")) == NULL) {
if (((h = getlogin()) != NULL &&
(pwd = getpwnam(h)) != NULL) ||