[PATCH 1/5] dlls/ntdll/tests: fully allocate SYSTEM_FIRMWARE_TABLE_INFORMATION

Eric Pouech eric.pouech at gmail.com
Thu Feb 17 04:16:23 CST 2022


this prevents mingw-gcc version 11 to generate warnings (-Warray-bounds)
Signed-off-by: Eric Pouech <eric.pouech at gmail.com>

---
 dlls/ntdll/tests/info.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dlls/ntdll/tests/info.c b/dlls/ntdll/tests/info.c
index e9d42127c3e..d6b323dd9d7 100644
--- a/dlls/ntdll/tests/info.c
+++ b/dlls/ntdll/tests/info.c
@@ -1461,7 +1461,7 @@ static void test_query_firmware(void)
     NTSTATUS status;
     SYSTEM_FIRMWARE_TABLE_INFORMATION *sfti;
 
-    sfti = HeapAlloc(GetProcessHeap(), 0, min_sfti_len);
+    sfti = HeapAlloc(GetProcessHeap(), 0, sizeof(*sfti));
     ok(!!sfti, "Failed to allocate memory\n");
 
     sfti->ProviderSignature = 0;




More information about the wine-devel mailing list