From bc0df4fd97a44dd69671b7faf8814307a552d400 Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Wed, 15 Nov 2023 14:48:20 +0100 Subject: [PATCH] winbind: Fix Coverity ID 1398910 Coverity isn't smart enough for talloc Signed-off-by: Volker Lendecke Reviewed-by: Jeremy Allison --- source3/winbindd/winbindd_ads.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/source3/winbindd/winbindd_ads.c b/source3/winbindd/winbindd_ads.c index d7a665abbc6..7e572e5d41f 100644 --- a/source3/winbindd/winbindd_ads.c +++ b/source3/winbindd/winbindd_ads.c @@ -449,6 +449,8 @@ static NTSTATUS query_user_list(struct winbindd_domain *domain, rids = talloc_realloc(mem_ctx, rids, uint32_t, count); if (prids != NULL) { *prids = rids; + } else { + TALLOC_FREE(rids); } status = NT_STATUS_OK; -- 2.47.3