new_parent_dn = &p_dn; /* New Parent unless newSuperior given */
- if ( newSuperior != NULL ) {
+ if ( newSuperior->bv_val != NULL ) {
Debug( LDAP_DEBUG_TRACE,
"bdb_modrdn: new parent \"%s\" requested...\n",
newSuperior->bv_val, 0, 0 );
new_parent_dn = &p_dn; /* New Parent unless newSuperior given */
- if ( newSuperior != NULL ) {
+ if ( newSuperior->bv_val != NULL ) {
#ifdef NEW_LOGGING
LDAP_LOG(( "backend", LDAP_LEVEL_DETAIL1,
"ldbm_back_modrdn: new parent \"%s\" requested\n",
}
}
- if ( newSuperior != NULL ) {
+ if ( newSuperior && newSuperior->bv_val != NULL ) {
/* newSuperior == entry being moved?, if so ==> ERROR */
/* Get Entry with dn=newSuperior. Does newSuperior exist? */