Bug fix. == NULL changed to != NULL before freeing mem.

This commit is contained in:
Mark Valence 1999-12-05 22:22:37 +00:00
parent 7d98b59dfa
commit aa8c95a24a

View File

@ -182,7 +182,7 @@ ldap_init( LDAP_CONST char *defhost, int defport )
if (( ld->ld_selectinfo = ldap_new_select_info()) == NULL ) {
LDAP_FREE( (char*) ld->ld_options.ldo_defhost );
if ( ld->ld_options.ldo_defbase == NULL ) {
if ( ld->ld_options.ldo_defbase != NULL ) {
LDAP_FREE( (char*) ld->ld_options.ldo_defbase );
}
LDAP_FREE( (char*) ld );