From: Ralf Haferkamp Date: Tue, 16 Feb 2010 15:17:53 +0000 (+0000) Subject: fixed start_tls() error handling X-Git-Tag: MIGRATION_CVS2GIT~692 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=98252925e35b48fc3f83d2bd50427993cd19a5d4;p=openldap fixed start_tls() error handling --- diff --git a/contrib/ldapc++/src/LDAPAsynConnection.cpp b/contrib/ldapc++/src/LDAPAsynConnection.cpp index 13fc78d61b..65e7a09cf1 100644 --- a/contrib/ldapc++/src/LDAPAsynConnection.cpp +++ b/contrib/ldapc++/src/LDAPAsynConnection.cpp @@ -81,8 +81,9 @@ void LDAPAsynConnection::initialize(const std::string& uri){ } void LDAPAsynConnection::start_tls(){ - if( ldap_start_tls_s( cur_session, NULL, NULL ) != LDAP_SUCCESS ) { - throw LDAPException(this); + int ret = ldap_start_tls_s( cur_session, NULL, NULL ); + if( ret != LDAP_SUCCESS ) { + throw LDAPException(ret); } }