From 5f5072f99e30f9529ee5bcaa43dfe9713e2bcf8f Mon Sep 17 00:00:00 2001 From: JoergAtGithub <64457745+JoergAtGithub@users.noreply.github.com> Date: Sun, 14 May 2023 23:43:06 +0200 Subject: [PATCH] Fixed second occurence of CID1530054 (#554) --- windows/hidapi_descriptor_reconstruct.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/windows/hidapi_descriptor_reconstruct.c b/windows/hidapi_descriptor_reconstruct.c index c5f6119..a4efb25 100644 --- a/windows/hidapi_descriptor_reconstruct.c +++ b/windows/hidapi_descriptor_reconstruct.c @@ -321,7 +321,7 @@ int hid_winapi_descriptor_reconstruct_pp_data(void *preparsed_data, unsigned cha if ((coll_number_of_direct_childs[collection_node_idx] != 0) && (coll_parsed_flag[link_collection_nodes[collection_node_idx].FirstChild] == FALSE)) { coll_parsed_flag[link_collection_nodes[collection_node_idx].FirstChild] = TRUE; - coll_child_order[collection_node_idx] = malloc((coll_number_of_direct_childs[collection_node_idx]) * sizeof(coll_child_order[0])); + coll_child_order[collection_node_idx] = malloc((coll_number_of_direct_childs[collection_node_idx]) * sizeof(*coll_child_order[0])); { // Create list of child collection indices