ITS#10023 libldap: fix asynch connects

This is option #1
This commit is contained in:
Ian Puleston 2023-03-16 13:09:48 -07:00 committed by Quanah Gibson-Mount
parent 1cfe66906a
commit 12d2382b53

View file

@ -501,6 +501,11 @@ ldap_int_open_connection(
if( proto == LDAP_PROTO_UDP ) return 0;
#endif
if ( async && rc == -2) {
/* Need to let the connect complete asynchronously before we continue */
return -2;
}
#ifdef HAVE_TLS
if ((rc == 0 || rc == -2) && ( ld->ld_options.ldo_tls_mode == LDAP_OPT_X_TLS_HARD ||
strcmp( srv->lud_scheme, "ldaps" ) == 0 ))