diff options
author | Noriko Hosoi <nhosoi@redhat.com> | 2009-01-08 23:11:43 +0000 |
---|---|---|
committer | Noriko Hosoi <nhosoi@redhat.com> | 2009-01-08 23:11:43 +0000 |
commit | 9bf48714b223b0921c9456d10716fe9727025549 (patch) | |
tree | 0e1348b3f530fd5702b050f43777c63666ab921a | |
parent | 3efb4a20fc64ed1be78bd1d812819f998ca74b01 (diff) | |
download | ds-9bf48714b223b0921c9456d10716fe9727025549.tar.gz ds-9bf48714b223b0921c9456d10716fe9727025549.tar.xz ds-9bf48714b223b0921c9456d10716fe9727025549.zip |
Resolves: #436830
Summary: Memory leak in ns-slapd's Class Of Service
Fix Description: When all the necessary values for the template cache are not
available, the allocated memory should be discarded. One of them pCosPriority
was missed to release.
-rw-r--r-- | ldap/servers/plugins/cos/cos_cache.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/ldap/servers/plugins/cos/cos_cache.c b/ldap/servers/plugins/cos/cos_cache.c index aa042670..29a0d0d7 100644 --- a/ldap/servers/plugins/cos/cos_cache.c +++ b/ldap/servers/plugins/cos/cos_cache.c @@ -1190,7 +1190,7 @@ static int cos_dn_tmpl_entries_cb (Slapi_Entry* e, void *callback_data) { { while(dnVals[valIndex]) { - if(dnVals[valIndex]->bv_val) + if(dnVals[valIndex]->bv_val) cos_cache_add_attrval(pSneakyVal, dnVals[valIndex]->bv_val); @@ -1269,6 +1269,8 @@ static int cos_dn_tmpl_entries_cb (Slapi_Entry* e, void *callback_data) { cos_cache_del_attrval_list(&pDn); if(pAttributes) cos_cache_del_attr_list(&pAttributes); + if(pCosPriority) + cos_cache_del_attrval_list(&pCosPriority); } } /* |