From 650ced22c89c0cf7f345c69fa03379876f2d1be8 Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Tue, 5 May 2009 21:54:01 +0000 Subject: [PATCH] More for ITS#5326 - don't free ora_e->e_name if same as o_req_dn --- servers/slapd/back-bdb/add.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/servers/slapd/back-bdb/add.c b/servers/slapd/back-bdb/add.c index e18feb33eb..b44f86fe64 100644 --- a/servers/slapd/back-bdb/add.c +++ b/servers/slapd/back-bdb/add.c @@ -305,7 +305,8 @@ retry: /* transaction retry */ dnRdn( &op->ora_e->e_name, &rdn ); build_new_dn( &newdn, &p->e_name, &rdn, NULL ); - ber_memfree( op->ora_e->e_name.bv_val ); + if ( op->ora_e->e_name.bv_val != op->o_req_dn.bv_val ) + ber_memfree( op->ora_e->e_name.bv_val ); op->ora_e->e_name = newdn; /* FIXME: should check whether -- 2.39.5