- (dtucker) [openbsd-compat/pwcache.c] Shrink ifdef area to prevent unused

variable warnings.
This commit is contained in:
Darren Tucker 2010-01-16 13:53:52 +11:00
parent dab129bef5
commit 612e400c68
2 changed files with 6 additions and 4 deletions

View File

@ -9,6 +9,8 @@
- markus@cvs.openbsd.org 2010/01/15 09:24:23
[sftp-common.c]
unused
- (dtucker) [openbsd-compat/pwcache.c] Shrink ifdef area to prevent unused
variable warnings.
20100115
- (dtucker) OpenBSD CVS Sync

View File

@ -58,12 +58,12 @@ user_from_uid(uid_t uid, int nouser)
cp = c_uid + (uid & MASK);
if (cp->uid != uid || cp->name == NULL) {
#ifdef HAVE_SETPASSENT
if (pwopen == 0) {
#ifdef HAVE_SETPASSENT
setpassent(1);
#endif
pwopen = 1;
}
#endif
if ((pw = getpwuid(uid)) == NULL) {
if (nouser)
return (NULL);
@ -93,12 +93,12 @@ group_from_gid(gid_t gid, int nogroup)
cp = c_gid + (gid & MASK);
if (cp->gid != gid || cp->name == NULL) {
#ifdef HAVE_SETGROUPENT
if (gropen == 0) {
#ifdef HAVE_SETGROUPENT
setgroupent(1);
#endif
gropen = 1;
}
#endif
if ((gr = getgrgid(gid)) == NULL) {
if (nogroup)
return (NULL);