[v5,01/10] member: replace zero length array with flex array

Message ID 20231129024221.57653-2-stephen@networkplumber.org (mailing list archive)
State Accepted
Delegated to: Thomas Monjalon
Headers
Series Replace zero length arrays |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Stephen Hemminger Nov. 29, 2023, 2:39 a.m. UTC
  Zero length arrays are GNU extension. Replace with
standard flex array.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Reviewed-by: Tyler Retzlaff <roretzla@linux.microsoft.com>
---
 lib/member/rte_member_heap.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
  

Patch

diff --git a/lib/member/rte_member_heap.h b/lib/member/rte_member_heap.h
index 9c4a01aebe95..ab6319bc2de4 100644
--- a/lib/member/rte_member_heap.h
+++ b/lib/member/rte_member_heap.h
@@ -26,7 +26,7 @@  struct hash {
 	uint16_t bkt_cnt;
 	uint16_t num_item;
 	uint32_t seed;
-	struct hash_bkt buckets[0];
+	struct hash_bkt buckets[];
 };
 
 struct node {