summaryrefslogtreecommitdiffstats
path: root/ipa-server/ipa-slapi-plugins
diff options
context:
space:
mode:
authorRich Megginson <rmeggins@redhat.com>2008-08-20 14:06:34 -0600
committerRob Crittenden <rcritten@redhat.com>2008-10-13 14:09:04 -0400
commit4bc89c427e5ecc47052a7489a9d4f8d18fbc1856 (patch)
treeb2f4287c1c610e065d6aad656e2cbd058ca53cd3 /ipa-server/ipa-slapi-plugins
parentc80ecc8c2af350483f3316727395cb0e5bb3600e (diff)
downloadfreeipa-4bc89c427e5ecc47052a7489a9d4f8d18fbc1856.tar.gz
freeipa-4bc89c427e5ecc47052a7489a9d4f8d18fbc1856.tar.xz
freeipa-4bc89c427e5ecc47052a7489a9d4f8d18fbc1856.zip
fix some memory leaks
Diffstat (limited to 'ipa-server/ipa-slapi-plugins')
-rw-r--r--ipa-server/ipa-slapi-plugins/ipa-winsync/ipa-winsync-config.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/ipa-server/ipa-slapi-plugins/ipa-winsync/ipa-winsync-config.c b/ipa-server/ipa-slapi-plugins/ipa-winsync/ipa-winsync-config.c
index dc13e6e5..1cf2c7a3 100644
--- a/ipa-server/ipa-slapi-plugins/ipa-winsync/ipa-winsync-config.c
+++ b/ipa-server/ipa-slapi-plugins/ipa-winsync/ipa-winsync-config.c
@@ -506,6 +506,7 @@ ipa_winsync_config_destroy_domain(
slapi_entry_free(iwdc->domain_e);
iwdc->domain_e = NULL;
slapi_ch_free_string(&iwdc->realm_name);
+ slapi_ch_free_string(&iwdc->homedir_prefix);
slapi_ch_free((void **)&iwdc);
return;
@@ -749,7 +750,8 @@ ipa_winsync_config_refresh_domain(
slapi_entry_add_valueset(iwdc->domain_e, "objectclass", new_user_objclasses);
/* set the default gid number */
- sv = slapi_value_new_string(default_gid);
+ sv = slapi_value_new_string_passin(default_gid);
+ default_gid = NULL; /* passin owns the memory */
if (!slapi_entry_attr_has_syntax_value(iwdc->domain_e, "gidNumber", sv)) {
slapi_entry_add_value(iwdc->domain_e, "gidNumber", sv);
}
@@ -767,6 +769,7 @@ out:
slapi_ch_free_string(&default_group_filter);
slapi_ch_free_string(&default_group_name);
slapi_ch_free_string(&real_group_filter);
+ slapi_ch_free_string(&default_gid);
if (LDAP_SUCCESS != ret) {
slapi_ch_free_string(&iwdc->realm_name);