From: Michael Adam Date: Wed, 6 Aug 2025 09:27:48 +0000 (+0200) Subject: s3:passdb: Fix CIDs 1596750,1596751 uninitialized pointer read X-Git-Tag: tdb-1.4.14~1 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=46989fb6e74e2efed166c80f06174a10ac4daaf4;p=thirdparty%2Fsamba.git s3:passdb: Fix CIDs 1596750,1596751 uninitialized pointer read This fixes two coverity issues of type CID 1596750 - uninitialized pointer read CID 1596751 - uninitialized pointer read It fixes one occurrence in each of pdb_samba_dsdb_create_user and pdb_samba_dsdb_create_alias Signed-off-by: Michael Adam Reviewed-by: Alexander Bokovoy Reviewed-by: Rabinarayan Panigrahi Reviewed-by: Shachar Sharon Autobuild-User(master): Anoop C S Autobuild-Date(master): Thu Aug 7 11:20:25 UTC 2025 on atb-devel-224 --- diff --git a/source3/passdb/pdb_samba_dsdb.c b/source3/passdb/pdb_samba_dsdb.c index 0678f7516d1..96d9819316b 100644 --- a/source3/passdb/pdb_samba_dsdb.c +++ b/source3/passdb/pdb_samba_dsdb.c @@ -768,7 +768,7 @@ static NTSTATUS pdb_samba_dsdb_create_user(struct pdb_methods *m, { struct pdb_samba_dsdb_state *state = talloc_get_type_abort( m->private_data, struct pdb_samba_dsdb_state); - struct dom_sid *sid; + struct dom_sid *sid = NULL; struct ldb_dn *dn; NTSTATUS status; TALLOC_CTX *tmp_ctx = talloc_new(mem_ctx); @@ -1582,7 +1582,7 @@ static NTSTATUS pdb_samba_dsdb_create_alias(struct pdb_methods *m, TALLOC_CTX *frame = talloc_stackframe(); struct pdb_samba_dsdb_state *state = talloc_get_type_abort( m->private_data, struct pdb_samba_dsdb_state); - struct dom_sid *sid; + struct dom_sid *sid = NULL; struct ldb_dn *dn; NTSTATUS status;