]> git.sur5r.net Git - openldap/commitdiff
don't compare freed pointers (no harm)
authorPierangelo Masarati <ando@openldap.org>
Mon, 9 May 2005 09:32:44 +0000 (09:32 +0000)
committerPierangelo Masarati <ando@openldap.org>
Mon, 9 May 2005 09:32:44 +0000 (09:32 +0000)
servers/slapd/overlays/rwm.c

index c4f827ac4fb72b83f1b7fd71eb01c17bd81fb0fd..4ff18d6573aafac930bf906a970f95307f78064f 100644 (file)
@@ -73,14 +73,14 @@ rwm_op_dn_massage( Operation *op, SlapReply *rs, void *cookie )
                return LDAP_SUCCESS;
        }
 
-       op->o_tmpfree( op->o_req_ndn.bv_val, op->o_tmpmemctx );
-       op->o_req_ndn = ndn;
        if ( op->o_req_dn.bv_val != op->o_req_ndn.bv_val ) {
                op->o_tmpfree( op->o_req_dn.bv_val, op->o_tmpmemctx );
                op->o_req_dn = dn;
        } else {
                op->o_req_dn = ndn;
        }
+       op->o_tmpfree( op->o_req_ndn.bv_val, op->o_tmpmemctx );
+       op->o_req_ndn = ndn;
 
        return LDAP_SUCCESS;
 }