Commit 29eda9c7 authored by Kurt Zeilenga's avatar Kurt Zeilenga
Browse files

LDAPworldP15: Internal LDAP function rename

parent 1cad5fd9
......@@ -107,7 +107,7 @@ do_abandon( LDAP *ld, int origid, int msgid )
err = 0;
if ( sendabandon ) {
/* create a message to send */
if ( (ber = alloc_ber_with_options( ld )) == NULLBER ) {
if ( (ber = ldap_alloc_ber_with_options( ld )) == NULLBER ) {
err = -1;
ld->ld_errno = LDAP_NO_MEMORY;
} else {
......@@ -151,10 +151,10 @@ do_abandon( LDAP *ld, int origid, int msgid )
#ifdef LDAP_REFERRALS
if ( lr != NULL ) {
if ( sendabandon ) {
free_connection( ld, lr->lr_conn, 0, 1 );
ldap_free_connection( ld, lr->lr_conn, 0, 1 );
}
if ( origid == msgid ) {
free_request( ld, lr );
ldap_free_request( ld, lr );
}
}
#endif /* LDAP_REFERRALS */
......
......@@ -69,7 +69,7 @@ ldap_add( LDAP *ld, char *dn, LDAPMod **attrs )
Debug( LDAP_DEBUG_TRACE, "ldap_add\n", 0, 0, 0 );
/* create a message to send */
if ( (ber = alloc_ber_with_options( ld )) == NULLBER ) {
if ( (ber = ldap_alloc_ber_with_options( ld )) == NULLBER ) {
return( -1 );
}
......@@ -103,7 +103,7 @@ ldap_add( LDAP *ld, char *dn, LDAPMod **attrs )
}
/* send the message */
return( send_initial_request( ld, LDAP_REQ_ADD, dn, ber ));
return( ldap_send_initial_request( ld, LDAP_REQ_ADD, dn, ber ));
}
int
......
......@@ -214,12 +214,12 @@ uncache_entry_or_req( LDAP *ld,
void
add_request_to_cache( LDAP *ld, unsigned long msgtype, BerElement *request )
ldap_add_request_to_cache( LDAP *ld, unsigned long msgtype, BerElement *request )
{
LDAPMessage *new;
long len;
Debug( LDAP_DEBUG_TRACE, "add_request_to_cache\n", 0, 0, 0 );
Debug( LDAP_DEBUG_TRACE, "ldap_add_request_to_cache\n", 0, 0, 0 );
ld->ld_errno = LDAP_SUCCESS;
if ( ld->ld_cache == NULLLDCACHE ||
......@@ -229,7 +229,7 @@ add_request_to_cache( LDAP *ld, unsigned long msgtype, BerElement *request )
if (( new = (LDAPMessage *) calloc( 1, sizeof(LDAPMessage) ))
!= NULL ) {
if (( new->lm_ber = alloc_ber_with_options( ld )) == NULLBER ) {
if (( new->lm_ber = ldap_alloc_ber_with_options( ld )) == NULLBER ) {
free( (char *)new );
return;
}
......@@ -256,12 +256,12 @@ add_request_to_cache( LDAP *ld, unsigned long msgtype, BerElement *request )
void
add_result_to_cache( LDAP *ld, LDAPMessage *result )
ldap_add_result_to_cache( LDAP *ld, LDAPMessage *result )
{
LDAPMessage *m, **mp, *req, *new, *prev;
int err, keep;
Debug( LDAP_DEBUG_TRACE, "add_result_to_cache: id %d, type %d\n",
Debug( LDAP_DEBUG_TRACE, "ldap_add_result_to_cache: id %d, type %d\n",
result->lm_msgid, result->lm_msgtype, 0 );
if ( ld->ld_cache == NULLLDCACHE ||
......@@ -369,14 +369,14 @@ add_result_to_cache( LDAP *ld, LDAPMessage *result )
* will find them.
*/
int
check_cache( LDAP *ld, unsigned long msgtype, BerElement *request )
ldap_check_cache( LDAP *ld, unsigned long msgtype, BerElement *request )
{
LDAPMessage *m, *new, *prev, *next;
BerElement reqber;
int first, hash;
unsigned long validtime;
Debug( LDAP_DEBUG_TRACE, "check_cache\n", 0, 0, 0 );
Debug( LDAP_DEBUG_TRACE, "ldap_check_cache\n", 0, 0, 0 );
if ( ld->ld_cache == NULLLDCACHE ||
( ld->ld_cache->lc_enabled == 0 )) {
......
......@@ -170,7 +170,7 @@ cldap_open( char *host, int port )
if ( ld->ld_sb.sb_addrs == NULL
#ifdef LDAP_REFERRALS
|| ( ld->ld_defconn = new_connection( ld, NULL, 1,0,0 )) == NULL
|| ( ld->ld_defconn = ldap_new_connection( ld, NULL, 1,0,0 )) == NULL
#endif /* LDAP_REFERRALS */
) {
free( ld );
......@@ -316,7 +316,7 @@ cldap_result( LDAP *ld, int msgid, LDAPMessage **res,
"cldap_result waiting up to %d seconds for a response\n",
tv.tv_sec, 0, 0 );
ber_init( &ber, 0 );
set_ber_options( ld, &ber );
ldap_set_ber_options( ld, &ber );
if ( cldap_getmsg( ld, &tv, &ber ) == -1 ) {
ret = ld->ld_errno;
......@@ -432,7 +432,7 @@ cldap_parsemsg( LDAP *ld, int msgid, BerElement *ber,
tag != LBER_DEFAULT && rc != LDAP_SUCCESS;
tag = ber_next_element( ber, &len, cookie )) {
if (( ldm = (LDAPMessage *)calloc( 1, sizeof(LDAPMessage)))
== NULL || ( ldm->lm_ber = alloc_ber_with_options( ld ))
== NULL || ( ldm->lm_ber = ldap_alloc_ber_with_options( ld ))
== NULLBER ) {
rc = LDAP_NO_MEMORY;
break; /* return w/error*/
......@@ -506,7 +506,7 @@ cldap_parsemsg( LDAP *ld, int msgid, BerElement *ber,
#ifndef NO_CACHE
if ( ld->ld_cache != NULL ) {
add_result_to_cache( ld, ldm );
ldap_add_result_to_cache( ld, ldm );
}
#endif /* NO_CACHE */
......
......@@ -52,7 +52,7 @@ ldap_compare( LDAP *ld, char *dn, char *attr, char *value )
Debug( LDAP_DEBUG_TRACE, "ldap_compare\n", 0, 0, 0 );
/* create a message to send */
if ( (ber = alloc_ber_with_options( ld )) == NULLBER ) {
if ( (ber = ldap_alloc_ber_with_options( ld )) == NULLBER ) {
return( -1 );
}
......@@ -65,17 +65,17 @@ ldap_compare( LDAP *ld, char *dn, char *attr, char *value )
#ifndef NO_CACHE
if ( ld->ld_cache != NULL ) {
if ( check_cache( ld, LDAP_REQ_COMPARE, ber ) == 0 ) {
if ( ldap_check_cache( ld, LDAP_REQ_COMPARE, ber ) == 0 ) {
ber_free( ber, 1 );
ld->ld_errno = LDAP_SUCCESS;
return( ld->ld_msgid );
}
add_request_to_cache( ld, LDAP_REQ_COMPARE, ber );
ldap_add_request_to_cache( ld, LDAP_REQ_COMPARE, ber );
}
#endif /* NO_CACHE */
/* send the message */
return ( send_initial_request( ld, LDAP_REQ_COMPARE, dn, ber ));
return ( ldap_send_initial_request( ld, LDAP_REQ_COMPARE, dn, ber ));
}
int
......
......@@ -51,7 +51,7 @@ ldap_delete( LDAP *ld, char *dn )
Debug( LDAP_DEBUG_TRACE, "ldap_delete\n", 0, 0, 0 );
/* create a message to send */
if ( (ber = alloc_ber_with_options( ld )) == NULLBER ) {
if ( (ber = ldap_alloc_ber_with_options( ld )) == NULLBER ) {
return( -1 );
}
......@@ -63,7 +63,7 @@ ldap_delete( LDAP *ld, char *dn )
}
/* send the message */
return ( send_initial_request( ld, LDAP_REQ_DELETE, dn, ber ));
return ( ldap_send_initial_request( ld, LDAP_REQ_DELETE, dn, ber ));
}
......
......@@ -36,7 +36,7 @@ ldap_first_attribute( LDAP *ld, LDAPMessage *entry, BerElement **ber )
Debug( LDAP_DEBUG_TRACE, "ldap_first_attribute\n", 0, 0, 0 );
if ( (*ber = alloc_ber_with_options( ld )) == NULLBER ) {
if ( (*ber = ldap_alloc_ber_with_options( ld )) == NULLBER ) {
return( NULL );
}
......
......@@ -3,7 +3,7 @@
* Copyright (c) 1995 Regents of the University of Michigan.
* All rights reserved.
*
* getdxbyname - retrieve DX records from the DNS (from TXT records for now)
* ldap_getdxbyname - retrieve DX records from the DNS (from TXT records for now)
*/
#include <stdio.h>
#include <string.h>
......@@ -47,17 +47,17 @@ extern char *h_errlist[];
/*
* getdxbyname - lookup DNS DX records for domain and return an ordered
* ldap_getdxbyname - lookup DNS DX records for domain and return an ordered
* array.
*/
char **
getdxbyname( char *domain )
ldap_getdxbyname( char *domain )
{
unsigned char buf[ PACKETSZ ];
char **dxs;
int rc;
Debug( LDAP_DEBUG_TRACE, "getdxbyname( %s )\n", domain, 0, 0 );
Debug( LDAP_DEBUG_TRACE, "ldap_getdxbyname( %s )\n", domain, 0, 0 );
memset( buf, 0, sizeof( buf ));
......
......@@ -52,7 +52,7 @@ ldap_kerberos_bind1( LDAP *ld, char *dn )
BerElement *ber;
char *cred;
int rc, credlen;
char *get_kerberosv4_credentials();
char *ldap_get_kerberosv4_credentials();
#ifdef STR_TRANSLATION
int str_translation_on;
#endif /* STR_TRANSLATION */
......@@ -75,13 +75,13 @@ ldap_kerberos_bind1( LDAP *ld, char *dn )
if ( dn == NULL )
dn = "";
if ( (cred = get_kerberosv4_credentials( ld, dn, "ldapserver",
if ( (cred = ldap_get_kerberosv4_credentials( ld, dn, "ldapserver",
&credlen )) == NULL ) {
return( -1 ); /* ld_errno should already be set */
}
/* create a message to send */
if ( (ber = alloc_ber_with_options( ld )) == NULLBER ) {
if ( (ber = ldap_alloc_ber_with_options( ld )) == NULLBER ) {
free( cred );
return( -1 );
}
......@@ -119,7 +119,7 @@ ldap_kerberos_bind1( LDAP *ld, char *dn )
#endif /* !NO_CACHE */
/* send the message */
return ( send_initial_request( ld, LDAP_REQ_BIND, dn, ber ));
return ( ldap_send_initial_request( ld, LDAP_REQ_BIND, dn, ber ));
}
int
......@@ -159,7 +159,7 @@ ldap_kerberos_bind2( LDAP *ld, char *dn )
BerElement *ber;
char *cred;
int rc, credlen;
char *get_kerberosv4_credentials();
char *ldap_get_kerberosv4_credentials();
#ifdef STR_TRANSLATION
int str_translation_on;
#endif /* STR_TRANSLATION */
......@@ -169,13 +169,13 @@ ldap_kerberos_bind2( LDAP *ld, char *dn )
if ( dn == NULL )
dn = "";
if ( (cred = get_kerberosv4_credentials( ld, dn, "x500dsa", &credlen ))
if ( (cred = ldap_get_kerberosv4_credentials( ld, dn, "x500dsa", &credlen ))
== NULL ) {
return( -1 ); /* ld_errno should already be set */
}
/* create a message to send */
if ( (ber = alloc_ber_with_options( ld )) == NULLBER ) {
if ( (ber = ldap_alloc_ber_with_options( ld )) == NULLBER ) {
free( cred );
return( -1 );
}
......@@ -207,7 +207,7 @@ ldap_kerberos_bind2( LDAP *ld, char *dn )
}
/* send the message */
return ( send_initial_request( ld, LDAP_REQ_BIND, dn, ber ));
return ( ldap_send_initial_request( ld, LDAP_REQ_BIND, dn, ber ));
}
/* synchronous bind to DSA using kerberos */
......@@ -249,19 +249,19 @@ ldap_kerberos_bind_s( LDAP *ld, char *dn )
#ifndef AUTHMAN
/*
* get_kerberosv4_credentials - obtain kerberos v4 credentials for ldap.
* ldap_get_kerberosv4_credentials - obtain kerberos v4 credentials for ldap.
* The dn of the entry to which to bind is supplied. It's assumed the
* user already has a tgt.
*/
char *
get_kerberosv4_credentials( LDAP *ld, char *who, char *service, int *len )
ldap_get_kerberosv4_credentials( LDAP *ld, char *who, char *service, int *len )
{
KTEXT_ST ktxt;
int err;
char realm[REALM_SZ], *cred, *krbinstance;
Debug( LDAP_DEBUG_TRACE, "get_kerberosv4_credentials\n", 0, 0, 0 );
Debug( LDAP_DEBUG_TRACE, "ldap_get_kerberosv4_credentials\n", 0, 0, 0 );
if ( (err = krb_get_tf_realm( tkt_string(), realm )) != KSUCCESS ) {
#ifndef NO_USERINTERFACE
......
......@@ -27,14 +27,14 @@
* in cache.c
*/
#ifdef NEEDPROTOS
void add_request_to_cache( LDAP *ld, unsigned long msgtype,
void ldap_add_request_to_cache( LDAP *ld, unsigned long msgtype,
BerElement *request );
void add_result_to_cache( LDAP *ld, LDAPMessage *result );
int check_cache( LDAP *ld, unsigned long msgtype, BerElement *request );
void ldap_add_result_to_cache( LDAP *ld, LDAPMessage *result );
int ldap_check_cache( LDAP *ld, unsigned long msgtype, BerElement *request );
#else /* NEEDPROTOS */
void add_request_to_cache();
void add_result_to_cache();
int check_cache();
void ldap_add_request_to_cache();
void ldap_add_result_to_cache();
int ldap_check_cache();
#endif /* NEEDPROTOS */
......@@ -43,10 +43,10 @@ int check_cache();
* in kerberos.c
*/
#ifdef NEEDPROTOS
char *get_kerberosv4_credentials( LDAP *ld, char *who, char *service,
char *ldap_get_kerberosv4_credentials( LDAP *ld, char *who, char *service,
int *len );
#else /* NEEDPROTOS */
char *get_kerberosv4_credentials();
char *ldap_get_kerberosv4_credentials();
#endif /* NEEDPROTOS */
#endif /* KERBEROS */
......@@ -67,17 +67,17 @@ int open_ldap_connection();
* in os-ip.c
*/
#ifdef NEEDPROTOS
int connect_to_host( Sockbuf *sb, char *host, unsigned long address, int port,
int ldap_connect_to_host( Sockbuf *sb, char *host, unsigned long address, int port,
int async );
void close_connection( Sockbuf *sb );
void ldap_close_connection( Sockbuf *sb );
#else /* NEEDPROTOS */
int connect_to_host();
void close_connection();
int ldap_connect_to_host();
void ldap_close_connection();
#endif /* NEEDPROTOS */
#ifdef KERBEROS
#ifdef NEEDPROTOS
char *host_connected_to( Sockbuf *sb );
char *ldap_host_connected_to( Sockbuf *sb );
#else /* NEEDPROTOS */
char *host_connected_to();
#endif /* NEEDPROTOS */
......@@ -86,22 +86,22 @@ char *host_connected_to();
#ifdef LDAP_REFERRALS
#ifdef NEEDPROTOS
int do_ldap_select( LDAP *ld, struct timeval *timeout );
void *new_select_info( void );
void free_select_info( void *sip );
void mark_select_write( LDAP *ld, Sockbuf *sb );
void mark_select_read( LDAP *ld, Sockbuf *sb );
void mark_select_clear( LDAP *ld, Sockbuf *sb );
int is_read_ready( LDAP *ld, Sockbuf *sb );
int is_write_ready( LDAP *ld, Sockbuf *sb );
void *ldap_new_select_info( void );
void ldap_free_select_info( void *sip );
void ldap_mark_select_write( LDAP *ld, Sockbuf *sb );
void ldap_mark_select_read( LDAP *ld, Sockbuf *sb );
void ldap_mark_select_clear( LDAP *ld, Sockbuf *sb );
int ldap_is_read_ready( LDAP *ld, Sockbuf *sb );
int ldap_is_write_ready( LDAP *ld, Sockbuf *sb );
#else /* NEEDPROTOS */
int do_ldap_select();
void *new_select_info();
void free_select_info();
void mark_select_write();
void mark_select_read();
void mark_select_clear();
int is_read_ready();
int is_write_ready();
void *ldap_new_select_info();
void ldap_free_select_info();
void ldap_mark_select_write();
void ldap_mark_select_read();
void ldap_mark_select_clear();
int ldap_is_read_ready();
int ldap_is_write_ready();
#endif /* NEEDPROTOS */
#endif /* LDAP_REFERRALS */
......@@ -110,46 +110,46 @@ int is_write_ready();
* in request.c
*/
#ifdef NEEDPROTOS
int send_initial_request( LDAP *ld, unsigned long msgtype,
int ldap_send_initial_request( LDAP *ld, unsigned long msgtype,
char *dn, BerElement *ber );
BerElement *alloc_ber_with_options( LDAP *ld );
void set_ber_options( LDAP *ld, BerElement *ber );
BerElement *ldap_alloc_ber_with_options( LDAP *ld );
void ldap_set_ber_options( LDAP *ld, BerElement *ber );
#else /* NEEDPROTOS */
int send_initial_request();
BerElement *alloc_ber_with_options();
void set_ber_options();
int ldap_send_initial_request();
BerElement *ldap_alloc_ber_with_options();
void ldap_set_ber_options();
#endif /* NEEDPROTOS */
#if defined( LDAP_REFERRALS ) || defined( LDAP_DNS )
#ifdef NEEDPROTOS
int send_server_request( LDAP *ld, BerElement *ber, int msgid,
int ldap_send_server_request( LDAP *ld, BerElement *ber, int msgid,
LDAPRequest *parentreq, LDAPServer *srvlist, LDAPConn *lc,
int bind );
LDAPConn *new_connection( LDAP *ld, LDAPServer **srvlistp, int use_ldsb,
LDAPConn *ldap_new_connection( LDAP *ld, LDAPServer **srvlistp, int use_ldsb,
int connect, int bind );
LDAPRequest *find_request_by_msgid( LDAP *ld, int msgid );
void free_request( LDAP *ld, LDAPRequest *lr );
void free_connection( LDAP *ld, LDAPConn *lc, int force, int unbind );
void dump_connection( LDAP *ld, LDAPConn *lconns, int all );
void dump_requests_and_responses( LDAP *ld );
LDAPRequest *ldap_find_request_by_msgid( LDAP *ld, int msgid );
void ldap_free_request( LDAP *ld, LDAPRequest *lr );
void ldap_free_connection( LDAP *ld, LDAPConn *lc, int force, int unbind );
void ldap_dump_connection( LDAP *ld, LDAPConn *lconns, int all );
void ldap_dump_requests_and_responses( LDAP *ld );
#else /* NEEDPROTOS */
int send_server_request();
LDAPConn *new_connection();
LDAPRequest *find_request_by_msgid();
void free_request();
void free_connection();
void dump_connection();
void dump_requests_and_responses();
int ldap_send_server_request();
LDAPConn *ldap_new_connection();
LDAPRequest *ldap_find_request_by_msgid();
void ldap_free_request();
void ldap_free_connection();
void ldap_dump_connection();
void ldap_dump_requests_and_responses();
#endif /* NEEDPROTOS */
#endif /* LDAP_REFERRALS || LDAP_DNS */
#ifdef LDAP_REFERRALS
#ifdef NEEDPROTOS
int chase_referrals( LDAP *ld, LDAPRequest *lr, char **errstrp, int *hadrefp );
int append_referral( LDAP *ld, char **referralsp, char *s );
int ldap_chase_referrals( LDAP *ld, LDAPRequest *lr, char **errstrp, int *hadrefp );
int ldap_append_referral( LDAP *ld, char **referralsp, char *s );
#else /* NEEDPROTOS */
int chase_referrals();
int append_referral();
int ldap_chase_referrals();
int ldap_append_referral();
#endif /* NEEDPROTOS */
#endif /* LDAP_REFERRALS */
......@@ -170,10 +170,10 @@ BerElement *ldap_build_search_req();
*/
#ifdef NEEDPROTOS
int ldap_ld_free( LDAP *ld, int close );
int send_unbind( LDAP *ld, Sockbuf *sb );
int ldap_send_unbind( LDAP *ld, Sockbuf *sb );
#else /* NEEDPROTOS */
int ldap_ld_free();
int send_unbind();
int ldap_send_unbind();
#endif /* NEEDPROTOS */
......@@ -182,9 +182,9 @@ int send_unbind();
* in getdxbyname.c
*/
#ifdef NEEDPROTOS
char **getdxbyname( char *domain );
char **ldap_getdxbyname( char *domain );
#else /* NEEDPROTOS */
char **getdxbyname();
char **ldap_getdxbyname();
#endif /* NEEDPROTOS */
#endif /* LDAP_DNS */
......
......@@ -69,7 +69,7 @@ ldap_modify( LDAP *ld, char *dn, LDAPMod **mods )
Debug( LDAP_DEBUG_TRACE, "ldap_modify\n", 0, 0, 0 );
/* create a message to send */
if ( (ber = alloc_ber_with_options( ld )) == NULLBER ) {
if ( (ber = ldap_alloc_ber_with_options( ld )) == NULLBER ) {
return( -1 );
}
......@@ -105,7 +105,7 @@ ldap_modify( LDAP *ld, char *dn, LDAPMod **mods )
}
/* send the message */
return( send_initial_request( ld, LDAP_REQ_MODIFY, dn, ber ));
return( ldap_send_initial_request( ld, LDAP_REQ_MODIFY, dn, ber ));
}
int
......
......@@ -53,7 +53,7 @@ ldap_modrdn2( LDAP *ld, char *dn, char *newrdn, int deleteoldrdn )
Debug( LDAP_DEBUG_TRACE, "ldap_modrdn\n", 0, 0, 0 );
/* create a message to send */
if ( (ber = alloc_ber_with_options( ld )) == NULLBER ) {
if ( (ber = ldap_alloc_ber_with_options( ld )) == NULLBER ) {
return( -1 );
}
......@@ -65,7 +65,7 @@ ldap_modrdn2( LDAP *ld, char *dn, char *newrdn, int deleteoldrdn )
}
/* send the message */
return ( send_initial_request( ld, LDAP_REQ_MODRDN, dn, ber ));
return ( ldap_send_initial_request( ld, LDAP_REQ_MODRDN, dn, ber ));
}
int
......
......@@ -81,7 +81,7 @@ ldap_open( char *host, int port )
}
srv->lsrv_port = ld->ld_defport;
if (( ld->ld_defconn = new_connection( ld, &srv, 1,1,0 )) == NULL ) {
if (( ld->ld_defconn = ldap_new_connection( ld, &srv, 1,1,0 )) == NULL ) {
if ( ld->ld_defhost != NULL ) free( srv->lsrv_host );
free( (char *)srv );
ldap_ld_free( ld, 0 );
......@@ -126,7 +126,7 @@ ldap_init( char *defhost, int defport )
}
#ifdef LDAP_REFERRALS
if (( ld->ld_selectinfo = new_select_info()) == NULL ) {
if (( ld->ld_selectinfo = ldap_new_select_info()) == NULL ) {
free( (char*)ld );
return( NULL );
}
......@@ -136,7 +136,7 @@ ldap_init( char *defhost, int defport )
if ( defhost != NULL &&
( ld->ld_defhost = strdup( defhost )) == NULL ) {
#ifdef LDAP_REFERRALS
free_select_info( ld->ld_selectinfo );
ldap_free_select_info( ld->ld_selectinfo );
#endif /* LDAP_REFERRALS */
free( (char*)ld );
return( NULL );
......@@ -201,13 +201,13 @@ open_ldap_connection( LDAP *ld, Sockbuf *sb, char *host, int defport,
port = defport;
}
if (( rc = connect_to_host( sb, curhost, 0L,
if (( rc = ldap_connect_to_host( sb, curhost, 0L,
port, async )) != -1 ) {
break;
}
}
} else {
rc = connect_to_host( sb, NULL, htonl( INADDR_LOOPBACK ),
rc = ldap_connect_to_host( sb, NULL, htonl( INADDR_LOOPBACK ),
defport, async );
}
......@@ -217,7 +217,7 @@ open_ldap_connection( LDAP *ld, Sockbuf *sb, char *host, int defport,
if ( krbinstancep != NULL ) {
#ifdef KERBEROS
if (( *krbinstancep = host_connected_to( sb )) != NULL &&
if (( *krbinstancep = ldap_host_connected_to( sb )) != NULL &&
( p = strchr( *krbinstancep, '.' )) != NULL ) {
*p = '\0';
}
......
......@@ -64,9 +64,10 @@ static char copyright[] = "@(#) Copyright (c) 1995 Regents of the University of
#endif /* DOS */
#endif /* MACOS */
#include "ldap-int.h"
int
connect_to_host( Sockbuf *sb, char *host, unsigned long address,
ldap_connect_to_host( Sockbuf *sb, char *host, unsigned long address,
int port, int async )
/*
* if host == NULL, connect using address
......@@ -85,7 +86,7 @@ connect_to_host( Sockbuf *sb, char *host, unsigned long address,
#endif /* LDAP_REFERRALS */
#endif /* notyet */
Debug( LDAP_DEBUG_TRACE, "connect_to_host: %s:%d\n",
Debug( LDAP_DEBUG_TRACE, "ldap_connect_to_host: %s:%d\n",
( host == NULL ) ? "(by address)" : host, ntohs( port ), 0 );
connected = use_hp = 0;
......@@ -174,7 +175,7 @@ connect_to_host( Sockbuf *sb, char *host, unsigned long address,
void
close_connection( Sockbuf *sb )
ldap_close_connection( Sockbuf *sb )
{