From 3b2961fcc203485d17f30d083a88a11e1e9a4b00 Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Wed, 9 Nov 2011 15:34:53 -0800 Subject: [PATCH] More debug msg null pointer checks --- servers/slapd/back-mdb/index.c | 4 ++-- servers/slapd/back-mdb/tools.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/servers/slapd/back-mdb/index.c b/servers/slapd/back-mdb/index.c index 4d2dc01457..2bde863a3a 100644 --- a/servers/slapd/back-mdb/index.c +++ b/servers/slapd/back-mdb/index.c @@ -496,7 +496,7 @@ mdb_index_entry( Debug( LDAP_DEBUG_TRACE, "=> index_entry_%s( %ld, \"%s\" )\n", opid == SLAP_INDEX_DELETE_OP ? "del" : "add", - (long) e->e_id, e->e_dn ); + (long) e->e_id, e->e_dn ? e->e_dn : "" ); /* add each attribute to the indexes */ for ( ; ap != NULL; ap = ap->a_next ) { @@ -569,7 +569,7 @@ mdb_index_entry( Debug( LDAP_DEBUG_TRACE, "<= index_entry_%s( %ld, \"%s\" ) success\n", opid == SLAP_INDEX_DELETE_OP ? "del" : "add", - (long) e->e_id, e->e_dn ); + (long) e->e_id, e->e_dn ? e->e_dn : "" ); return LDAP_SUCCESS; } diff --git a/servers/slapd/back-mdb/tools.c b/servers/slapd/back-mdb/tools.c index 2d733849a5..0ce1e22d21 100644 --- a/servers/slapd/back-mdb/tools.c +++ b/servers/slapd/back-mdb/tools.c @@ -805,8 +805,8 @@ int mdb_tool_entry_reindex( */ Debug( LDAP_DEBUG_TRACE, - "=> " LDAP_XSTRING(mdb_tool_entry_reindex) "( %ld, \"%s\" )\n", - (long) id, e->e_dn, 0 ); + "=> " LDAP_XSTRING(mdb_tool_entry_reindex) "( %ld )\n", + (long) id, 0, 0 ); op.o_hdr = &ohdr; op.o_bd = be; -- 2.39.5