From: Kurt Zeilenga Date: Wed, 19 Jul 2000 22:53:22 +0000 (+0000) Subject: Fix up SASL interact error checking X-Git-Tag: LDBM_PRE_GIANT_RWLOCK~2409 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=5c10406b9e5c377f81def44e3229ee864d2a324f;p=openldap Fix up SASL interact error checking --- diff --git a/libraries/libldap/cyrus.c b/libraries/libldap/cyrus.c index d56cb50ce1..9cd66814fb 100644 --- a/libraries/libldap/cyrus.c +++ b/libraries/libldap/cyrus.c @@ -340,6 +340,9 @@ sasl_err2ldap( int saslerr ) case SASL_CONTINUE: rc = LDAP_MORE_RESULTS_TO_RETURN; break; + case SASL_INTERACT: + rc = LDAP_LOCAL_ERROR; + break; case SASL_OK: rc = LDAP_SUCCESS; break; @@ -528,9 +531,10 @@ ldap_int_sasl_bind( } if( saslrc == SASL_INTERACT ) { + int res; if( !interact ) break; - rc = (interact)( ld, flags, defaults, prompts ); - if( rc != LDAP_SUCCESS ) { + res = (interact)( ld, flags, defaults, prompts ); + if( res != LDAP_SUCCESS ) { break; } } @@ -578,7 +582,7 @@ ldap_int_sasl_bind( if( saslrc == SASL_INTERACT ) { int res; if( !interact ) break; - rc = (interact)( ld, flags, defaults, prompts ); + res = (interact)( ld, flags, defaults, prompts ); if( res != LDAP_SUCCESS ) { break; }