summaryrefslogtreecommitdiff
path: root/source3/winbindd/winbindd_cm.c
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2013-09-04 13:58:18 -0700
committerJeremy Allison <jra@samba.org>2013-09-05 09:17:27 -0700
commit32037e0533f720ebbd3f49c5951c4ef30aac9985 (patch)
treef9db5cdac1da5bd09fb0e2a6e373a96a9847c08b /source3/winbindd/winbindd_cm.c
parent6b915bfd0f4194453c1b01158f2c2772b2a2df2f (diff)
downloadsamba-32037e0533f720ebbd3f49c5951c4ef30aac9985.tar.gz
samba-32037e0533f720ebbd3f49c5951c4ef30aac9985.tar.bz2
samba-32037e0533f720ebbd3f49c5951c4ef30aac9985.zip
Add a talloc context to sitename_fetch().
Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org>
Diffstat (limited to 'source3/winbindd/winbindd_cm.c')
-rw-r--r--source3/winbindd/winbindd_cm.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/source3/winbindd/winbindd_cm.c b/source3/winbindd/winbindd_cm.c
index bf0e70d20b..17ede8c5cf 100644
--- a/source3/winbindd/winbindd_cm.c
+++ b/source3/winbindd/winbindd_cm.c
@@ -1161,7 +1161,7 @@ static bool dcip_to_name(TALLOC_CTX *mem_ctx,
if (domain->primary && (ads->config.flags & NBT_SERVER_KDC)) {
if (ads_closest_dc(ads)) {
- char *sitename = sitename_fetch(ads->config.realm);
+ char *sitename = sitename_fetch(mem_ctx, ads->config.realm);
/* We're going to use this KDC for this realm/domain.
If we are using sites, then force the krb5 libs
@@ -1173,7 +1173,7 @@ static bool dcip_to_name(TALLOC_CTX *mem_ctx,
pss,
*name);
- SAFE_FREE(sitename);
+ TALLOC_FREE(sitename);
} else {
/* use an off site KDC */
create_local_private_krb5_conf_for_domain(domain->alt_name,
@@ -1279,7 +1279,7 @@ static bool get_dcs(TALLOC_CTX *mem_ctx, struct winbindd_domain *domain,
get_dc_name(domain->name, domain->alt_name, dcname, &ss);
- sitename = sitename_fetch(domain->alt_name);
+ sitename = sitename_fetch(mem_ctx, domain->alt_name);
if (sitename) {
/* Do the site-specific AD dns lookup first. */
@@ -1303,7 +1303,7 @@ static bool get_dcs(TALLOC_CTX *mem_ctx, struct winbindd_domain *domain,
}
SAFE_FREE(ip_list);
- SAFE_FREE(sitename);
+ TALLOC_FREE(sitename);
iplist_size = 0;
}