summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Dieter Wallnöfer <mwallnoefer@yahoo.de>2010-04-11 12:56:50 +0200
committerMatthias Dieter Wallnöfer <mwallnoefer@yahoo.de>2010-04-11 13:20:44 +0200
commit568ca2433d0d2292047979abbfcb03543bb27a67 (patch)
tree282dbaed1207d989c8e1d733ed4d003edf2801ab
parentc7dfe736a88549f5793521609aca68ca85545c1b (diff)
downloadsamba-568ca2433d0d2292047979abbfcb03543bb27a67.tar.gz
samba-568ca2433d0d2292047979abbfcb03543bb27a67.tar.bz2
samba-568ca2433d0d2292047979abbfcb03543bb27a67.zip
s4:samdb_server_site_dn - free unused DNs in the right way
-rw-r--r--source4/dsdb/common/util.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source4/dsdb/common/util.c b/source4/dsdb/common/util.c
index b469b06232..c6870da234 100644
--- a/source4/dsdb/common/util.c
+++ b/source4/dsdb/common/util.c
@@ -1469,16 +1469,16 @@ struct ldb_dn *samdb_server_site_dn(struct ldb_context *ldb, TALLOC_CTX *mem_ctx
struct ldb_dn *server_site_dn;
/* TODO: there must be a saner way to do this!! */
-
server_dn = samdb_server_dn(ldb, mem_ctx);
if (!server_dn) return NULL;
servers_dn = ldb_dn_get_parent(mem_ctx, server_dn);
+ talloc_free(server_dn);
if (!servers_dn) return NULL;
server_site_dn = ldb_dn_get_parent(mem_ctx, servers_dn);
+ talloc_free(servers_dn);
- talloc_free(server_dn);
return server_site_dn;
}