From: Stefan Metzmacher Date: Wed, 29 Jan 2025 08:55:20 +0000 (+0100) Subject: s4:dsdb/common: use talloc_zero() in samdb_result_dom_sid_attrs() X-Git-Tag: tevent-0.17.0~780 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=11d1cde2566bcae1e60da8ca942fd63702ddab97;p=thirdparty%2Fsamba.git s4:dsdb/common: use talloc_zero() in samdb_result_dom_sid_attrs() This means struct auth_SidAttr can change without leaving uninitialized memory. Signed-off-by: Stefan Metzmacher Reviewed-by: Jennifer Sutton --- diff --git a/source4/dsdb/common/util.c b/source4/dsdb/common/util.c index 757133eb277..9e50982f97a 100644 --- a/source4/dsdb/common/util.c +++ b/source4/dsdb/common/util.c @@ -386,7 +386,7 @@ struct auth_SidAttr *samdb_result_dom_sid_attrs(TALLOC_CTX *mem_ctx, const struc if (v == NULL) { return NULL; } - sid = talloc(mem_ctx, struct auth_SidAttr); + sid = talloc_zero(mem_ctx, struct auth_SidAttr); if (sid == NULL) { return NULL; }