]> git.sur5r.net Git - openldap/commitdiff
ITS#159 fix. ldaphost may be NULL when used as printf "%s" argument.
authorKurt Zeilenga <kurt@openldap.org>
Mon, 24 May 1999 20:08:32 +0000 (20:08 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Mon, 24 May 1999 20:08:32 +0000 (20:08 +0000)
clients/tools/ldapsearch.c

index 83b1720e76523957b4c6cda975123d9c825484f4..7a8a84e6a8741ffa1a96d0c693f70be5887bb595 100644 (file)
@@ -265,7 +265,9 @@ main( int argc, char **argv )
 #endif
 
     if ( verbose ) {
-       printf( "ldap_init( %s, %d )\n", ldaphost, ldapport );
+       printf( "ldap_init( %s, %d )\n",
+               (ldaphost != NULL) ? ldaphost : "<DEFAULT>",
+               ldapport );
     }
 
     if (( ld = ldap_init( ldaphost, ldapport )) == NULL ) {