From: Volker Lendecke Date: Tue, 10 Jan 2017 13:28:41 +0000 (+0000) Subject: winbind: Fix CID 1398530 Resource leak X-Git-Tag: talloc-2.1.9~427 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e8008fb36d7821eafffc5f0ff2ee6f080f84c4ae;p=thirdparty%2Fsamba.git winbind: Fix CID 1398530 Resource leak Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison --- diff --git a/source3/winbindd/winbindd_ads.c b/source3/winbindd/winbindd_ads.c index 83579686ff4..b14f21e3644 100644 --- a/source3/winbindd/winbindd_ads.c +++ b/source3/winbindd/winbindd_ads.c @@ -356,8 +356,9 @@ static NTSTATUS query_user_list(struct winbindd_domain *domain, } if (!ads_pull_sid(ads, msg, "objectSid", &user_sid)) { - DBG_INFO("No sid for %s !?\n", - ads_get_dn(ads, talloc_tos(), msg)); + char *dn = ads_get_dn(ads, talloc_tos(), msg); + DBG_INFO("No sid for %s !?\n", dn); + TALLOC_FREE(dn); continue; }