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