setres[gu]id implicit decl warning on Linux glibc

Pekka Savola pekkas at netcore.fi
Fri Aug 15 06:46:51 EST 2003


Hi,

With recent snapshots, I noted a warning in compilation on Red Hat Linux 
7.3 system with glibc 2.2.5:

uidswap.c: In function `permanently_set_uid':
uidswap.c:155: warning: implicit declaration of function `setresgid'
uidswap.c:168: warning: implicit declaration of function `setresuid'

The problem appears to be that these should be prototyped in unistd.h, but
aren't. There are no prototype for these anywhere at all. The man page
gives a hint that this is a long-standing bug/feature.

On the other hand, the definitions seem to exist in glibc 2.3.

I looked a bit how to fix this in openssh, but couldn't quickly figure a 
nice way to do it.  It may not be worth a fix anyway.

Just letting you folks know, if someone has a nice autoconf trick handy 
(for example) or is bothered by this warning..

-- 
Pekka Savola                 "You each name yourselves king, yet the
Netcore Oy                    kingdom bleeds."
Systems. Networks. Security. -- George R.R. Martin: A Clash of Kings




More information about the openssh-unix-dev mailing list