Deleted Added
full compact
36c36
< RCSID("$Id: expand_hostname.c,v 1.7 2000/02/02 04:42:57 assar Exp $");
---
> RCSID("$Id: expand_hostname.c,v 1.8 2000/02/20 02:25:29 assar Exp $");
83a84,108
> * handle the case of the hostname being unresolvable and thus identical
> */
>
> static krb5_error_code
> vanilla_hostname (krb5_context context,
> const char *orig_hostname,
> char **new_hostname,
> char ***realms)
> {
> krb5_error_code ret;
>
> ret = copy_hostname (context, orig_hostname, new_hostname);
> if (ret)
> return ret;
> strlwr (*new_hostname);
>
> ret = krb5_get_host_realm (context, *new_hostname, realms);
> if (ret) {
> free (*new_hostname);
> return ret;
> }
> return 0;
> }
>
> /*
103c128,130
< return copy_hostname (context, orig_hostname, new_hostname);
---
> return vanilla_hostname (context, orig_hostname, new_hostname,
> realms);
>
107,108c134,137
< if (ret)
< goto out;
---
> if (ret) {
> freeaddrinfo (ai);
> return ret;
> }
111,112c140,143
< if (ret == 0)
< goto out;
---
> if (ret == 0) {
> freeaddrinfo (ai);
> return 0;
> }
116,119c147
< ret = copy_hostname (context, orig_hostname, new_hostname);
< out:
< freeaddrinfo (ai);
< return ret;
---
> return vanilla_hostname (context, orig_hostname, new_hostname, realms);