isupper()/isspace()/islower() to int.
* t_std_conf.c (test_locate_kdc): krb5_locate_kdc expects a struct
sockaddr *** as a third argument instead of sockaddr **.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@13339
dc483132-0cff-0310-8789-
dd5450dbe970
+2001-06-12 Ezra Peisach <epeisach@mit.edu>
+
+ * sn2princ.c, hst_realm.c, an_to_ln.c: Cast argument to
+ isupper()/isspace()/islower() to int.
+
+ * t_std_conf.c (test_locate_kdc): krb5_locate_kdc expects a struct
+ sockaddr *** as a third argument instead of sockaddr **.
+
2001-06-07 Ezra Peisach <epeisach@mit.edu>
* ktdefname.c (krb5_kt_default_name): Get rid of a variable that
*/
for (cp = *contextp; *cp; ) {
/* Skip leading whitespace */
- while (isspace(*cp))
+ while (isspace((int) (*cp)))
cp++;
/*
*cout = '\0';
current++;
/* Point past number */
- while (isdigit(*current))
+ while (isdigit((int) (*current)))
current++;
}
else
/* Trim the value. */
cp = &mapping_values[nvalid-1]
[strlen(mapping_values[nvalid-1])];
- while (isspace(*cp)) cp--;
+ while (isspace((int) (*cp))) cp--;
cp++;
*cp = '\0';
local_host[sizeof(local_host) - 1] = '\0';
for (cp = local_host; *cp; cp++) {
- if (isupper(*cp))
+ if (isupper((int) (*cp)))
*cp = tolower(*cp);
}
l = strlen(local_host);
/* Assume the realm name is upper case */
for (cp = realm; *cp; cp++)
- if (islower(*cp))
+ if (islower((int) (*cp)))
*cp = toupper(*cp);
} else {
/* We are defaulting to the local realm */
if (type == KRB5_NT_SRV_HST)
for (cp = remote_host; *cp; cp++)
- if (isupper(*cp))
+ if (isupper((int) (*cp)))
*cp = tolower(*cp);
/*
krb5_context ctx;
char *realm;
{
- struct sockaddr *addrs;
+ struct sockaddr **addrs;
struct sockaddr_in *s_sin;
int i, naddrs;
int get_masters=0;
retval = krb5_locate_kdc(ctx, &rlm, &addrs, &naddrs,
get_masters);
if (retval) {
- com_err("krb5_get_krbhst", retval, 0);
+ com_err("krb5_locate_kdc", retval, 0);
return;
}
- printf("krb_get_krbhst(%s) returned:", realm);
+ printf("krb_locate_kdc(%s) returned:", realm);
for (i=0; i < naddrs; i++) {
- s_sin = (struct sockaddr_in *) &addrs[i];
+ s_sin = (struct sockaddr_in *) addrs[i];
printf(" %s/%d", inet_ntoa(s_sin->sin_addr),
ntohs(s_sin->sin_port));
}