X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=libraries%2Flibldap%2Fldap-int.h;h=591c3e4e74cebf992273719649df51dd4b69dea1;hb=7887ef7e92a4b91d20814242322dfc33d3ebb0ee;hp=971412b26051bb901b53435b95469a0a94eb1aee;hpb=e80b5d4040da74165f60e6a7f78f8fc9e4ee6500;p=openldap diff --git a/libraries/libldap/ldap-int.h b/libraries/libldap/ldap-int.h index 971412b260..591c3e4e74 100644 --- a/libraries/libldap/ldap-int.h +++ b/libraries/libldap/ldap-int.h @@ -1,7 +1,7 @@ /* ldap-int.h - defines & prototypes internal to the LDAP library */ /* $OpenLDAP$ */ /* - * Copyright 1998-2000 The OpenLDAP Foundation, All Rights Reserved. + * Copyright 1998-2002 The OpenLDAP Foundation, All Rights Reserved. * COPYING RESTRICTIONS APPLY, see COPYRIGHT file */ /* Portions @@ -18,6 +18,10 @@ #include "../liblber/lber-int.h" +#ifdef LDAP_R_COMPILE +#include +#endif + #ifdef HAVE_CYRUS_SASL /* the need for this should be removed */ #include @@ -51,7 +55,9 @@ #undef Debug #define Debug( level, fmt, arg1, arg2, arg3 ) \ - ldap_log_printf( NULL, (level), (fmt), (arg1), (arg2), (arg3) ) + do { if ( ldap_debug & level ) \ + ldap_log_printf( NULL, (level), (fmt), (arg1), (arg2), (arg3) ); \ + } while ( 0 ) #define LDAP_Debug( subsystem, level, fmt, arg1, arg2, arg3 )\ ldap_log_printf( NULL, (level), (fmt), (arg1), (arg2), (arg3) ) @@ -194,7 +200,7 @@ typedef struct ldap_conn { #endif BerElement *lconn_ber; /* ber receiving on this conn. */ - struct ldap_conn *lconn_next; + struct ldap_conn *lconn_next; } LDAPConn; @@ -304,8 +310,6 @@ struct ldap { #define LDAP_VALID(ld) ( (ld)->ld_valid == LDAP_VALID_SESSION ) #ifdef LDAP_R_COMPILE -#include - #ifdef HAVE_RES_QUERY LDAP_V ( ldap_pvt_thread_mutex_t ) ldap_int_resolv_mutex; #endif @@ -327,19 +331,18 @@ LDAP_F ( void ) ldap_int_initialize_global_options LDAP_P(( /* memory.c */ /* simple macros to realloc for now */ -#define LDAP_INT_MALLOC(s) (LBER_MALLOC((s))) -#define LDAP_INT_CALLOC(n,s) (LBER_CALLOC((n),(s))) -#define LDAP_INT_REALLOC(p,s) (LBER_REALLOC((p),(s))) -#define LDAP_INT_FREE(p) (LBER_FREE((p))) -#define LDAP_INT_VFREE(v) (LBER_VFREE((void **)(v))) -#define LDAP_INT_STRDUP(s) (LBER_STRDUP((s))) - #define LDAP_MALLOC(s) (LBER_MALLOC((s))) #define LDAP_CALLOC(n,s) (LBER_CALLOC((n),(s))) #define LDAP_REALLOC(p,s) (LBER_REALLOC((p),(s))) #define LDAP_FREE(p) (LBER_FREE((p))) #define LDAP_VFREE(v) (LBER_VFREE((void **)(v))) #define LDAP_STRDUP(s) (LBER_STRDUP((s))) +#define LDAP_STRNDUP(s,l) (LBER_STRNDUP((s),(l))) + +/* + * in error.c + */ +LDAP_F (void) ldap_int_error_init( void ); /* * in unit-int.c @@ -410,7 +413,7 @@ LDAP_F (int) ldap_int_open_connection( LDAP *ld, /* * in os-ip.c */ -LDAP_F (int) ldap_int_tblsize; +LDAP_V (int) ldap_int_tblsize; LDAP_F (int) ldap_int_timeval_dup( struct timeval **dest, const struct timeval *tm ); LDAP_F (int) ldap_connect_to_host( LDAP *ld, Sockbuf *sb, int proto, const char *host, unsigned long address, int port, @@ -423,7 +426,7 @@ LDAP_F (char *) ldap_host_connected_to( Sockbuf *sb ); #endif LDAP_F (void) ldap_int_ip_init( void ); -LDAP_F (int) do_ldap_select( LDAP *ld, struct timeval *timeout ); +LDAP_F (int) ldap_int_select( LDAP *ld, struct timeval *timeout ); LDAP_F (void *) ldap_new_select_info( void ); LDAP_F (void) ldap_free_select_info( void *sip ); LDAP_F (void) ldap_mark_select_write( LDAP *ld, Sockbuf *sb ); @@ -481,10 +484,9 @@ LDAP_F (BerElement *) ldap_build_search_req LDAP_P(( ber_int_t timelimit, ber_int_t sizelimit )); -/* - * in string.c - */ - /* see */ +LDAP_F( int ) ldap_int_put_filter LDAP_P(( + BerElement *ber, + const char *str )); /* * in unbind.c @@ -561,6 +563,11 @@ LDAP_F (int) ldap_int_sasl_bind LDAP_P(( LDAP_SASL_INTERACT_PROC *interact, void *defaults )); +/* in schema.c */ +LDAP_F (char *) ldap_int_parse_numericoid LDAP_P(( + const char **sp, + int *code, + const int flags )); /* * in tls.c