From 26e327f32e0dc8a2ddc2e4df08cdb6335b33de92 Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Sun, 6 Jan 2002 07:21:06 +0000 Subject: [PATCH] Fix some debug statements --- servers/slapd/acl.c | 4 ++-- servers/slapd/back-bdb/delete.c | 4 ++-- servers/slapd/back-bdb/dn2id.c | 2 +- servers/slapd/back-bdb/modify.c | 2 +- servers/slapd/back-bdb/referral.c | 2 +- servers/slapd/back-ldbm/attribute.c | 8 ++++---- servers/slapd/back-ldbm/cache.c | 8 ++++---- servers/slapd/back-ldbm/delete.c | 4 ++-- servers/slapd/tools/slapcommon.c | 2 +- 9 files changed, 18 insertions(+), 18 deletions(-) diff --git a/servers/slapd/acl.c b/servers/slapd/acl.c index 5fd5d7f428..e63e71351c 100644 --- a/servers/slapd/acl.c +++ b/servers/slapd/acl.c @@ -1045,12 +1045,12 @@ acl_check_modlist( LDAP_LOG(( "aci", LDAP_LEVEL_DETAIL1, "acl_check_modlist: conn %d backend default %s access %s to \"%s\"\n", conn->c_connid, access2str( ACL_WRITE ), - be->be_dfltaccess >= ACL_WRITE ? "granted" : "denied", op->o_dn )); + be->be_dfltaccess >= ACL_WRITE ? "granted" : "denied", op->o_dn.bv_val )); #else Debug( LDAP_DEBUG_ACL, "=> access_allowed: backend default %s access %s to \"%s\"\n", access2str( ACL_WRITE ), - be->be_dfltaccess >= ACL_WRITE ? "granted" : "denied", op->o_dn ); + be->be_dfltaccess >= ACL_WRITE ? "granted" : "denied", op->o_dn.bv_val ); #endif return be->be_dfltaccess >= ACL_WRITE; diff --git a/servers/slapd/back-bdb/delete.c b/servers/slapd/back-bdb/delete.c index b5f50b3626..53a8928c84 100644 --- a/servers/slapd/back-bdb/delete.c +++ b/servers/slapd/back-bdb/delete.c @@ -92,7 +92,7 @@ retry: /* transaction retry */ Debug( LDAP_DEBUG_ARGS, "<=- bdb_delete: no such object %s\n", - dn, 0, 0); + dn->bv_val, 0, 0); if ( matched != NULL ) { matched_dn = ch_strdup( matched->e_dn ); @@ -221,7 +221,7 @@ retry: /* transaction retry */ case 0: Debug(LDAP_DEBUG_ARGS, "<=- bdb_delete: non-leaf %s\n", - dn, 0, 0); + dn->bv_val, 0, 0); rc = LDAP_NOT_ALLOWED_ON_NONLEAF; text = "subtree delete not supported"; break; diff --git a/servers/slapd/back-bdb/dn2id.c b/servers/slapd/back-bdb/dn2id.c index 64b74aa9e7..17b0650dfc 100644 --- a/servers/slapd/back-bdb/dn2id.c +++ b/servers/slapd/back-bdb/dn2id.c @@ -344,7 +344,7 @@ bdb_dn2id_children( free( key.data ); Debug( LDAP_DEBUG_TRACE, "<= bdb_dn2id_children( %s ): %schildren (%d)\n", - dn, + dn->bv_val, rc == 0 ? "" : ( rc == DB_NOTFOUND ? "no " : db_strerror(rc) ), rc ); diff --git a/servers/slapd/back-bdb/modify.c b/servers/slapd/back-bdb/modify.c index 1d7c3c067e..336c291056 100644 --- a/servers/slapd/back-bdb/modify.c +++ b/servers/slapd/back-bdb/modify.c @@ -171,7 +171,7 @@ bdb_modify( DB_TXN *ltid = NULL; struct bdb_op_info opinfo; - Debug( LDAP_DEBUG_ARGS, "bdb_modify: %s\n", dn, 0, 0 ); + Debug( LDAP_DEBUG_ARGS, "bdb_modify: %s\n", dn->bv_val, 0, 0 ); if( 0 ) { retry: /* transaction retry */ diff --git a/servers/slapd/back-bdb/referral.c b/servers/slapd/back-bdb/referral.c index 7b401f8bf4..074491b4b4 100644 --- a/servers/slapd/back-bdb/referral.c +++ b/servers/slapd/back-bdb/referral.c @@ -61,7 +61,7 @@ bdb_referrals( Debug( LDAP_DEBUG_TRACE, "bdb_referrals: op=%ld target=\"%s\" matched=\"%s\"\n", - (long) op->o_tag, dn, matched_dn ); + (long) op->o_tag, dn->bv_val, matched_dn ); if( is_entry_referral( matched ) ) { rc = LDAP_OTHER; diff --git a/servers/slapd/back-ldbm/attribute.c b/servers/slapd/back-ldbm/attribute.c index ecafef36b1..5a7dfa0869 100644 --- a/servers/slapd/back-ldbm/attribute.c +++ b/servers/slapd/back-ldbm/attribute.c @@ -40,7 +40,7 @@ ldbm_back_attribute( #ifdef NEW_LOGGING LDAP_LOG(( "backend", LDAP_LEVEL_ARGS, - "ldbm_back_attribute: gr dn: \"%s\"\n", entry_ndn )); + "ldbm_back_attribute: gr dn: \"%s\"\n", entry_ndn->bv_val )); LDAP_LOG(( "backend", LDAP_LEVEL_ARGS, "ldbm_back_attribute: at: \"%s\"\n", entry_at_name)); LDAP_LOG(( "backend", LDAP_LEVEL_ARGS, @@ -49,7 +49,7 @@ ldbm_back_attribute( #else Debug( LDAP_DEBUG_ARGS, "=> ldbm_back_attribute: gr dn: \"%s\"\n", - entry_ndn, 0, 0 ); + entry_ndn->bv_val, 0, 0 ); Debug( LDAP_DEBUG_ARGS, "=> ldbm_back_attribute: at: \"%s\"\n", entry_at_name, 0, 0 ); @@ -79,11 +79,11 @@ ldbm_back_attribute( #ifdef NEW_LOGGING LDAP_LOG(( "backend", LDAP_LEVEL_INFO, "ldbm_back_attribute: cannot find entry (%s)\n", - entry_ndn )); + entry_ndn->bv_val )); #else Debug( LDAP_DEBUG_ACL, "=> ldbm_back_attribute: cannot find entry: \"%s\"\n", - entry_ndn, 0, 0 ); + entry_ndn->bv_val, 0, 0 ); #endif return LDAP_NO_SUCH_OBJECT; diff --git a/servers/slapd/back-ldbm/cache.c b/servers/slapd/back-ldbm/cache.c index bde62fa0f5..1a9f1c6fcf 100644 --- a/servers/slapd/back-ldbm/cache.c +++ b/servers/slapd/back-ldbm/cache.c @@ -611,11 +611,11 @@ try_again: #ifdef NEW_LOGGING LDAP_LOG(( "cache", LDAP_LEVEL_INFO, "cache_find_entry_dn2id: (%s) %ld not ready: %d\n", - ndn, id, state )); + ndn->bv_val, id, state )); #else Debug(LDAP_DEBUG_TRACE, "====> cache_find_entry_dn2id(\"%s\"): %ld (not ready) %d\n", - ndn, id, state); + ndn->bv_val, id, state); #endif @@ -633,11 +633,11 @@ try_again: #ifdef NEW_LOGGING LDAP_LOG(( "cache", LDAP_LEVEL_DETAIL1, "cache_find_entry_dn2id: (%s): %ld %d tries\n", - ndn, id, count )); + ndn->bv_val, id, count )); #else Debug(LDAP_DEBUG_TRACE, "====> cache_find_entry_dn2id(\"%s\"): %ld (%d tries)\n", - ndn, id, count); + ndn->bv_val, id, count); #endif diff --git a/servers/slapd/back-ldbm/delete.c b/servers/slapd/back-ldbm/delete.c index 74ff1b369b..5d2f63ec7e 100644 --- a/servers/slapd/back-ldbm/delete.c +++ b/servers/slapd/back-ldbm/delete.c @@ -103,10 +103,10 @@ ldbm_back_delete( if ( has_children( be, e ) ) { #ifdef NEW_LOGGING LDAP_LOG(( "backend", LDAP_LEVEL_ERR, - "ldbm_back_delete: (%s) is a non-leaf node.\n", dn )); + "ldbm_back_delete: (%s) is a non-leaf node.\n", dn->bv_val )); #else Debug(LDAP_DEBUG_ARGS, "<=- ldbm_back_delete: non leaf %s\n", - dn, 0, 0); + dn->bv_val, 0, 0); #endif send_ldap_result( conn, op, LDAP_NOT_ALLOWED_ON_NONLEAF, diff --git a/servers/slapd/tools/slapcommon.c b/servers/slapd/tools/slapcommon.c index 93556dee12..b608765127 100644 --- a/servers/slapd/tools/slapcommon.c +++ b/servers/slapd/tools/slapcommon.c @@ -217,7 +217,7 @@ slap_tool_init( rc = dnNormalize( NULL, &base, &nbase ); if( rc != LDAP_SUCCESS ) { fprintf( stderr, "%s: slap_init invalid suffix (\"%s\")\n", - progname, base ); + progname, base.bv_val ); exit( EXIT_FAILURE ); } -- 2.39.5