From: Ralph Boehme Date: Thu, 7 Nov 2024 13:11:48 +0000 (+0100) Subject: smbd: initialize delete_on_close in smbd_smb2_setinfo_lease_break_fsp_check() X-Git-Tag: tdb-1.4.13~621 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7653ae27023539f57c8e89d878d5836480fffbb6;p=thirdparty%2Fsamba.git smbd: initialize delete_on_close in smbd_smb2_setinfo_lease_break_fsp_check() CID 1634488: Uninitialized variables (UNINIT) /source3/smbd/smb2_setinfo.c: 475 in smbd_smb2_setinfo_lease_break_fsp_check() 469 &delete_on_close); 470 if (tevent_req_nterror(req, status)) { 471 return; 472 } 473 } 474 >>> CID 1634488: Uninitialized variables (UNINIT) >>> Using uninitialized value "delete_on_close". 475 if (!rename && !delete_on_close) { 476 return; 477 } 478 479 state->lck = get_existing_share_mode_lock(state, fsp->file_id); 480 if (state->lck == NULL) { Signed-off-by: Ralph Boehme Reviewed-by: Volker Lendecke Autobuild-User(master): Volker Lendecke Autobuild-Date(master): Thu Nov 7 17:21:53 UTC 2024 on atb-devel-224 --- diff --git a/source3/smbd/smb2_setinfo.c b/source3/smbd/smb2_setinfo.c index 84c651b1794..91280a52c07 100644 --- a/source3/smbd/smb2_setinfo.c +++ b/source3/smbd/smb2_setinfo.c @@ -456,7 +456,7 @@ static void smbd_smb2_setinfo_lease_break_fsp_check(struct tevent_req *req) struct tevent_req *subreq = NULL; struct timeval timeout; bool rename; - bool delete_on_close; + bool delete_on_close = false; NTSTATUS status; rename = (file_info_level == SMB2_FILE_RENAME_INFORMATION_INTERNAL);