]> git.sur5r.net Git - openldap/blobdiff - libraries/libldap/url.c
Add strdup.c from -llutil, renamed to ldap_strdup() and always used.
[openldap] / libraries / libldap / url.c
index 4de1a914e0562e47e09f8e0308f7f6e853030d99..bc6726164fe63cd7abd28f52b2aecff7ad1c9a18 100644 (file)
@@ -113,7 +113,7 @@ ldap_url_parse( char *url, LDAPURLDesc **ludpp )
        }
 
        /* make working copy of the remainder of the URL */
-       if (( url = strdup( url )) == NULL ) {
+       if (( url = ldap_strdup( url )) == NULL ) {
                ldap_free_urldesc( ludp );
                return( LDAP_URL_ERR_MEM );
        }
@@ -263,7 +263,7 @@ ldap_url_search( LDAP *ld, char *url, int attrsonly )
        if ( ludp->lud_host != NULL || ludp->lud_port != 0 ) {
 #ifdef LDAP_API_FEATURE_X_OPENLDAP_V2_REFERRALS
                if (( srv = (LDAPServer *)calloc( 1, sizeof( LDAPServer )))
-                   == NULL || ( srv->lsrv_host = strdup( ludp->lud_host ==
+                   == NULL || ( srv->lsrv_host = ldap_strdup( ludp->lud_host ==
                    NULL ? ld->ld_defhost : ludp->lud_host )) == NULL ) {
                        if ( srv != NULL ) {
                                free( srv );