]> git.sur5r.net Git - openldap/commitdiff
Additional error detail
authorKurt Zeilenga <kurt@openldap.org>
Tue, 15 Nov 2005 22:45:44 +0000 (22:45 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Tue, 15 Nov 2005 22:45:44 +0000 (22:45 +0000)
servers/slapd/sasl.c

index 58f8a963426db241eaf6f7d571277b68e62c27d3..9ba8c695a9dcc8c2cfe9f506390d503b70b5c202 100644 (file)
@@ -1447,6 +1447,9 @@ int slap_sasl_bind( Operation *op, SlapReply *rs )
                }
        } else if ( sc == SASL_CONTINUE ) {
                rs->sr_err = LDAP_SASL_BIND_IN_PROGRESS,
+#if SASL_VERSION_MAJOR >= 2
+               rs->sr_text = sasl_errdetail( ctx );
+#endif
                rs->sr_sasldata = &response;
                send_ldap_sasl( op, rs );
 
@@ -1459,9 +1462,7 @@ int slap_sasl_bind( Operation *op, SlapReply *rs )
        }
 
 #if SASL_VERSION_MAJOR < 2
-       if( response.bv_len ) {
-               ch_free( response.bv_val );
-       }
+       if( response.bv_len ) ch_free( response.bv_val );
 #endif
 
        Debug(LDAP_DEBUG_TRACE, "<== slap_sasl_bind: rc=%d\n", rs->sr_err, 0, 0);