/* $OpenLDAP$ */
/*
- * Copyright 1999-2003 The OpenLDAP Foundation, All Rights Reserved.
+ * Copyright 1999-2002 The OpenLDAP Foundation, All Rights Reserved.
* COPYING RESTRICTIONS APPLY, see COPYRIGHT file
*/
}
}
- if( saslrc == SASL_INTERACT ) {
- int res;
-
#if SASL_VERSION_MAJOR >= 2
- /* XXX the application should free interact results.
- * FIXME: this should happen only
- * if saslrc == SASL_INTERACT
- *
- * I assume that prompts->result is not needed
- * by the subsequent call to (interact)() */
- if ( prompts != NULL && prompts->result != NULL ) {
- LDAP_FREE( (void *)prompts->result );
- prompts->result = NULL;
- }
+ /* XXX the application should free interact results. */
+ if ( prompts != NULL && prompts->result != NULL ) {
+ LDAP_FREE( (void *)prompts->result );
+ prompts->result = NULL;
+ }
#endif
+ if( saslrc == SASL_INTERACT ) {
+ int res;
if( !interact ) break;
res = (interact)( ld, flags, defaults, prompts );
if( res != LDAP_SUCCESS ) {