"Error: UNINIT (CWE-457):
samba-4.20.0rc2/source4/torture/smb2/lease.c:452: var_decl: Declaring variable ""h"" without initializer.
samba-4.20.0rc2/source4/torture/smb2/lease.c:516: uninit_use_in_call: Using uninitialized value ""h"" when calling ""smb2_util_close"".
514|
515| done:
516|-> smb2_util_close(tree, h);
517| smb2_util_close(tree, hnew);
518| smb2_util_close(tree, h2);"
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Martin Schwenke <mschwenke@ddn.com>
struct smb2_tree *tree)
{
TALLOC_CTX *mem_ctx = talloc_new(tctx);
- struct smb2_handle h, h2, hnew;
+ struct smb2_handle h = {
+ .data = {0},
+ };
+ struct smb2_handle h2 = {
+ .data = {0},
+ };
+ struct smb2_handle hnew = {
+ .data = {0},
+ };
NTSTATUS status;
struct smb2_create io;
struct smb2_lease ls;