diff --git a/servers/slapd/back-ldap/search.c b/servers/slapd/back-ldap/search.c index a329a09451..b3a68b3141 100644 --- a/servers/slapd/back-ldap/search.c +++ b/servers/slapd/back-ldap/search.c @@ -563,7 +563,7 @@ finish:; ldap_back_quarantine( op, rs ); } - if ( freefilter ) { + if ( freefilter && filter.bv_val != op->ors_filterstr.bv_val ) { op->o_tmpfree( filter.bv_val, op->o_tmpmemctx ); }