mirror of
https://github.com/samba-team/samba.git
synced 2025-01-03 01:18:10 +03:00
s4:torture: Initialize union spoolss_KeyNames
"Error: UNINIT (CWE-457): samba-4.20.0rc2/source4/torture/rpc/spoolss.c:7835: var_decl: Declaring variable ""key_buffer"" without initializer. samba-4.20.0rc2/source4/torture/rpc/spoolss.c:7906: uninit_use: Using uninitialized value ""key_buffer.string_array"". 7904| 7905| if (array) { 7906|-> *array = key_buffer.string_array; 7907| } 7908|" Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Alexander Bokovoy <ab@samba.org>
This commit is contained in:
parent
a39cb60c3f
commit
d64242f676
@ -7832,7 +7832,7 @@ static bool test_EnumPrinterKey(struct torture_context *tctx,
|
||||
{
|
||||
struct spoolss_EnumPrinterKey r;
|
||||
uint32_t needed = 0;
|
||||
union spoolss_KeyNames key_buffer;
|
||||
union spoolss_KeyNames key_buffer = {};
|
||||
int32_t offered[] = { 0, 1, 2, 3, 4, 5, -1, -2, -3, -4, -5, 256, 512, 1024, 2048 };
|
||||
uint32_t _ndr_size;
|
||||
int i;
|
||||
|
Loading…
Reference in New Issue
Block a user