case 0:
break;
default:
+#ifdef NEW_LOGGING
+ LDAP_LOG (( "referral", LDAP_LEVEL_ERR,
+ "bdb_referrals: dn2entry failed: %s (%d)\n",
+ db_strerror(rc), rc ));
+#else
Debug( LDAP_DEBUG_TRACE,
"bdb_referrals: dn2entry failed: %s (%d)\n",
db_strerror(rc), rc, 0 );
+#endif
if (e != NULL) {
bdb_cache_return_entry_r(&bdb->bi_cache, e);
}
if ( matched != NULL ) {
matched_dn = ch_strdup( matched->e_dn );
+#ifdef NEW_LOGGING
+ LDAP_LOG (( "referral", LDAP_LEVEL_DETAIL1,
+ "bdb_referrals: op=%ld target=\"%s\" matched=\"%s\"\n",
+ (long) op->o_tag, dn->bv_val, matched_dn ));
+#else
Debug( LDAP_DEBUG_TRACE,
"bdb_referrals: op=%ld target=\"%s\" matched=\"%s\"\n",
(long) op->o_tag, dn->bv_val, matched_dn );
+#endif
if( is_entry_referral( matched ) ) {
rc = LDAP_OTHER;
BerVarray rrefs = referral_rewrite(
refs, &e->e_name, dn, LDAP_SCOPE_DEFAULT );
+#ifdef NEW_LOGGING
+ LDAP_LOG (( "referral", LDAP_LEVEL_DETAIL1,
+ "bdb_referrals: op=%ld target=\"%s\" matched=\"%s\"\n",
+ (long) op->o_tag, dn->bv_val, e->e_dn ));
+#else
Debug( LDAP_DEBUG_TRACE,
"bdb_referrals: op=%ld target=\"%s\" matched=\"%s\"\n",
(long) op->o_tag, dn->bv_val, e->e_dn );
+#endif
if( rrefs != NULL ) {
send_ldap_result( conn, op, rc = LDAP_REFERRAL,