ITS#159 fix. ldaphost may be NULL when used as printf "%s" argument.

This commit is contained in:
Kurt Zeilenga 1999-05-24 20:08:32 +00:00
parent 06239ebd66
commit fffc29df9b

View 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 ) {