(__ivaliduser): more cast to get rid of warnings

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@1472 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Assar Westerlund
1997-03-23 04:54:00 +00:00
parent 5c154e5e08
commit a50a8e90ab

View File

@@ -82,7 +82,8 @@ innetgr(const char *netgroup, const char *machine,
*/
static
int
__ivaliduser(FILE *hostf, u_int32_t raddr, const char *luser, const char *ruser)
__ivaliduser(FILE *hostf, u_int32_t raddr, const char *luser,
const char *ruser)
{
char *user, *p;
int ch;
@@ -170,7 +171,8 @@ __ivaliduser(FILE *hostf, u_int32_t raddr, const char *luser, const char *ruser)
break;
}
if (*(user+1) == '@') /* match a user by netgroup */
userok = innetgr(user+2, NULL, ruser, ypdomain);
userok = innetgr(user+2, NULL, (char *)ruser,
ypdomain);
else /* match a user by direct specification */
userok = !(strcmp(ruser, user+1));
break;
@@ -180,7 +182,7 @@ __ivaliduser(FILE *hostf, u_int32_t raddr, const char *luser, const char *ruser)
return(-1);
if (*(user+1) == '@') {
if (innetgr(user+2, NULL,
ruser, ypdomain))
(char *)ruser, ypdomain))
return(-1);
} else {
if (!strcmp(ruser, user+1))