From: Howard Chu Date: Thu, 25 Sep 2003 11:28:31 +0000 (+0000) Subject: Plug SLAPI leak X-Git-Tag: OPENLDAP_REL_ENG_2_1_MP~652 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=25e145f8c8ad1d847cde54db95f3d72dcc94aa11;p=openldap Plug SLAPI leak --- diff --git a/servers/slapd/result.c b/servers/slapd/result.c index c4311df736..c5a6e77771 100644 --- a/servers/slapd/result.c +++ b/servers/slapd/result.c @@ -373,7 +373,8 @@ send_ldap_response( #ifdef LDAP_SLAPI slapi_pblock_set( op->o_pb, SLAPI_RESULT_CODE, (void *)rs->sr_err ); slapi_pblock_set( op->o_pb, SLAPI_RESULT_MATCHED, ( rs->sr_matched != NULL ) ? (void *)ch_strdup( rs->sr_matched ) : NULL ); - slapi_pblock_set( op->o_pb, SLAPI_RESULT_TEXT, ( rs->sr_text != NULL ) ? (void *)ch_strdup( rs->sr_text ) : NULL ); + /* RESULT_TEXT is dup'd by pblock_set */ + slapi_pblock_set( op->o_pb, SLAPI_RESULT_TEXT, rs->sr_text ); #endif /* LDAP_SLAPI */ ldap_pvt_thread_mutex_lock( &num_sent_mutex );