diff --git a/lib/krb5/changepw.c b/lib/krb5/changepw.c index d2a282e80..69dfdf477 100644 --- a/lib/krb5/changepw.c +++ b/lib/krb5/changepw.c @@ -69,7 +69,7 @@ get_kdc_address (krb5_context context, if (hostent == NULL) hostent = gethostbyname2 (p, AF_INET); #else - hostent = gethostbyname (p); + hostent = roken_gethostbyname (p); #endif krb5_free_krbhst (context, hostlist); if (hostent == NULL) diff --git a/lib/krb5/get_addrs.c b/lib/krb5/get_addrs.c index b0e39a36b..862dd783a 100644 --- a/lib/krb5/get_addrs.c +++ b/lib/krb5/get_addrs.c @@ -66,7 +66,7 @@ gethostname_fallback (krb5_addresses *res) if (gethostname (hostname, sizeof(hostname))) return errno; - hostent = gethostbyname (hostname); + hostent = roken_gethostbyname (hostname); if (hostent == NULL) return errno; res->len = 1; diff --git a/lib/krb5/get_for_creds.c b/lib/krb5/get_for_creds.c index 2b3962f29..cbada1f4e 100644 --- a/lib/krb5/get_for_creds.c +++ b/lib/krb5/get_for_creds.c @@ -78,7 +78,7 @@ krb5_get_forwarded_creds (krb5_context context, if (out_creds == NULL) return ENOMEM; - hostent = gethostbyname (hostname); + hostent = roken_gethostbyname (hostname); if (hostent == NULL) return h_errno; /* XXX */ diff --git a/lib/krb5/get_host_realm.c b/lib/krb5/get_host_realm.c index 31e68822c..6a3137e4c 100644 --- a/lib/krb5/get_host_realm.c +++ b/lib/krb5/get_host_realm.c @@ -73,9 +73,11 @@ krb5_get_host_realm(krb5_context context, } addr.s_addr = inet_addr(host); - hostent = gethostbyname (host); + hostent = roken_gethostbyname (host); if (hostent == NULL && addr.s_addr != INADDR_NONE) - hostent = gethostbyaddr ((const char *)&addr, sizeof(addr), AF_INET); + hostent = roken_gethostbyaddr ((const char *)&addr, + sizeof(addr), + AF_INET); if (hostent != NULL) host = hostent->h_name; diff --git a/lib/krb5/get_port.c b/lib/krb5/get_port.c index f8a713618..aac922720 100644 --- a/lib/krb5/get_port.c +++ b/lib/krb5/get_port.c @@ -48,7 +48,7 @@ krb5_getportbyname (krb5_context context, { struct servent *sp; - if ((sp = getservbyname (service, proto)) == NULL) { + if ((sp = roken_getservbyname (service, proto)) == NULL) { krb5_warnx(context, "%s/%s unknown service, using default port %d", service, proto, default_port); return htons(default_port); diff --git a/lib/krb5/log.c b/lib/krb5/log.c index 534d70ef4..f3062e61d 100644 --- a/lib/krb5/log.c +++ b/lib/krb5/log.c @@ -179,7 +179,8 @@ close_syslog(void *data) } static krb5_error_code -open_syslog(krb5_context context, krb5_log_facility *facility, int min, int max, +open_syslog(krb5_context context, + krb5_log_facility *facility, int min, int max, const char *sev, const char *fac) { struct syslog_data *sd = malloc(sizeof(*sd)); @@ -195,8 +196,9 @@ open_syslog(krb5_context context, krb5_log_facility *facility, int min, int max, if(i == -1) i = LOG_AUTH; sd->priority |= i; - openlog(facility->program, LOG_PID | LOG_NDELAY, i); - return krb5_addlog_func(context, facility, min, max, log_syslog, close_syslog, sd); + roken_openlog(facility->program, LOG_PID | LOG_NDELAY, i); + return krb5_addlog_func(context, facility, min, max, + log_syslog, close_syslog, sd); } struct file_data{ diff --git a/lib/krb5/principal.c b/lib/krb5/principal.c index 5cac5e4dd..c6a23bb48 100644 --- a/lib/krb5/principal.c +++ b/lib/krb5/principal.c @@ -494,7 +494,7 @@ krb5_425_conv_principal_ext(krb5_context context, return HEIM_ERR_V4_PRINC_NO_CONV; } if(resolve){ - struct hostent *hp = gethostbyname(instance); + struct hostent *hp = roken_gethostbyname(instance); if(hp){ instance = hp->h_name; ret = krb5_make_principal(context, &pr, @@ -696,7 +696,7 @@ krb5_sname_to_principal (krb5_context context, sname = "host"; if(type == KRB5_NT_SRV_HST){ struct hostent *hp; - hp = gethostbyname(hostname); + hp = roken_gethostbyname(hostname); if(hp != NULL) hostname = hp->h_name; } diff --git a/lib/krb5/send_to_kdc.c b/lib/krb5/send_to_kdc.c index 67f05c7ef..aba0ca238 100644 --- a/lib/krb5/send_to_kdc.c +++ b/lib/krb5/send_to_kdc.c @@ -180,7 +180,7 @@ krb5_sendto_kdc (krb5_context context, if (hostent == NULL) hostent = gethostbyname2 (p, AF_INET); #else - hostent = gethostbyname (p); + hostent = roken_gethostbyname (p); #endif if(hostent == NULL) continue; diff --git a/lib/krb5/sock_principal.c b/lib/krb5/sock_principal.c index 3433eae71..d09bd3c60 100644 --- a/lib/krb5/sock_principal.c +++ b/lib/krb5/sock_principal.c @@ -70,9 +70,9 @@ krb5_sock_to_principal (krb5_context context, if (ret) return ret; - hostent = gethostbyaddr (address.address.data, - address.address.length, - family); + hostent = roken_gethostbyaddr (address.address.data, + address.address.length, + family); if (hostent == NULL) return h_errno;