summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRich Megginson <rmeggins@redhat.com>2008-08-27 21:05:25 +0000
committerRich Megginson <rmeggins@redhat.com>2008-08-27 21:05:25 +0000
commitb32761a5797fa5efb8ab65ae2d2e0c539357e73c (patch)
tree2634cac18917a9c5e2e0d507073f636ab67a3c19
parent3cbd862d52228960b9a9a735b81d4a2da14d0ee9 (diff)
downloadds-b32761a5797fa5efb8ab65ae2d2e0c539357e73c.tar.gz
ds-b32761a5797fa5efb8ab65ae2d2e0c539357e73c.tar.xz
ds-b32761a5797fa5efb8ab65ae2d2e0c539357e73c.zip
Resolves: bug 458507
Bug Description: Memory leak setting new password storage scheme Reviewed by: nkinder (Thanks!) Branch: HEAD Fix Description: In config_set_pw_storagescheme, new_schema is allocated in both the non apply and the apply case, but it is only freed in the apply case. The solution is to free it in the non apply case. Platforms tested: RHEL5, Fedora 8 Flag Day: no Doc impact: no QA impact: should be covered by regular nightly and manual testing New Tests integrated into TET: none
-rw-r--r--ldap/servers/slapd/libglobs.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/ldap/servers/slapd/libglobs.c b/ldap/servers/slapd/libglobs.c
index 21ffa4c2..eef97ecd 100644
--- a/ldap/servers/slapd/libglobs.c
+++ b/ldap/servers/slapd/libglobs.c
@@ -1510,6 +1510,8 @@ config_set_pw_storagescheme( const char *attrname, char *value, char *errorbuf,
slapdFrontendConfig->pw_storagescheme = new_scheme;
CFG_UNLOCK_WRITE(slapdFrontendConfig);
+ } else {
+ free_pw_scheme(new_scheme);
}
slapi_ch_free_string(&scheme_list);