summaryrefslogtreecommitdiff
path: root/source3/utils
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2009-04-07 00:40:46 +0200
committerGünther Deschner <gd@samba.org>2009-04-07 01:17:30 +0200
commitd71dec9259366e99beca69fcd9397bd38ed82c71 (patch)
tree963204bf8ced95db535348c57542edbbf3db26a3 /source3/utils
parenteeddbb6f8466d285fd103a3a4da9ebf5afbcb613 (diff)
downloadsamba-d71dec9259366e99beca69fcd9397bd38ed82c71.tar.gz
samba-d71dec9259366e99beca69fcd9397bd38ed82c71.tar.bz2
samba-d71dec9259366e99beca69fcd9397bd38ed82c71.zip
s3-libads: avoid NULL talloc context with ads_get_dn().
Guenther
Diffstat (limited to 'source3/utils')
-rw-r--r--source3/utils/net_ads.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/source3/utils/net_ads.c b/source3/utils/net_ads.c
index 8ff0cdfcf4..8e927becbe 100644
--- a/source3/utils/net_ads.c
+++ b/source3/utils/net_ads.c
@@ -503,7 +503,7 @@ static int ads_user_add(struct net_context *c, int argc, const char **argv)
ads_msgfree(ads, res);
status=ads_find_user_acct(ads, &res, argv[0]);
if (ADS_ERR_OK(status)) {
- userdn = ads_get_dn(ads, NULL, res);
+ userdn = ads_get_dn(ads, talloc_tos(), res);
ads_del_dn(ads, userdn);
TALLOC_FREE(userdn);
}
@@ -598,7 +598,7 @@ static int ads_user_delete(struct net_context *c, int argc, const char **argv)
ads_destroy(&ads);
return -1;
}
- userdn = ads_get_dn(ads, NULL, res);
+ userdn = ads_get_dn(ads, talloc_tos(), res);
ads_msgfree(ads, res);
rc = ads_del_dn(ads, userdn);
TALLOC_FREE(userdn);
@@ -757,7 +757,7 @@ static int ads_group_delete(struct net_context *c, int argc, const char **argv)
ads_destroy(&ads);
return -1;
}
- groupdn = ads_get_dn(ads, NULL, res);
+ groupdn = ads_get_dn(ads, talloc_tos(), res);
ads_msgfree(ads, res);
rc = ads_del_dn(ads, groupdn);
TALLOC_FREE(groupdn);
@@ -1740,7 +1740,7 @@ static int net_ads_printer_remove(struct net_context *c, int argc, const char **
return -1;
}
- prt_dn = ads_get_dn(ads, NULL, res);
+ prt_dn = ads_get_dn(ads, talloc_tos(), res);
ads_msgfree(ads, res);
rc = ads_del_dn(ads, prt_dn);
TALLOC_FREE(prt_dn);