Replace uids comparison by issetugid() call

This commit is contained in:
Andrey A. Chernov 1997-08-22 11:14:53 +00:00
parent 463695c856
commit 7b759a7f68
1 changed files with 2 additions and 2 deletions

View File

@ -115,9 +115,9 @@ tgetent(char *bp, const char *name)
strncpy(pathbuf, cp, PBUFSIZ); /* still can be tokenized */
pathbuf[PBUFSIZ - 1] = '\0';
/* XXX Should really be issetguid(), but we don't have that */
if (getuid() != geteuid() || getgid() != getegid())
if (issetugid())
strcpy(pathbuf, _PATH_DEF_SEC);
*fname++ = pathbuf; /* tokenize path into vector of names */
while (*++p)
if (*p == ' ' || *p == ':') {