[v4,4/4] app: examples: replace zero-length arrays with undimensioned ones
Checks
Commit Message
This patch replaces instances of zero-sized arrays i.e. those at the end
of structures with "[0]" with the more standard syntax of "[]".
Replacement was done using coccinelle script, with some cleanup of
whitespace afterwards.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Morten Brørup <mb@smartsharesystems.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
---
app/test/test_table_tables.c | 2 +-
examples/ip_reassembly/main.c | 2 +-
examples/ptpclient/ptpclient.c | 4 ++--
3 files changed, 4 insertions(+), 4 deletions(-)
@@ -53,7 +53,7 @@ struct rte_bucket_4_8 {
uint64_t next_valid;
uint64_t key[4];
/* Cache line 1 */
- uint8_t data[0];
+ uint8_t data[];
};
#if RTE_TABLE_HASH_LRU_STRATEGY == 3
@@ -126,7 +126,7 @@ struct mbuf_table {
uint32_t len;
uint32_t head;
uint32_t tail;
- struct rte_mbuf *m_table[0];
+ struct rte_mbuf *m_table[];
};
struct rx_queue {
@@ -90,7 +90,7 @@ struct sync_msg {
struct follow_up_msg {
struct ptp_header hdr;
struct tstamp precise_origin_tstamp;
- uint8_t suffix[0];
+ uint8_t suffix[];
} __rte_packed;
struct delay_req_msg {
@@ -102,7 +102,7 @@ struct delay_resp_msg {
struct ptp_header hdr;
struct tstamp rx_tstamp;
struct port_id req_port_id;
- uint8_t suffix[0];
+ uint8_t suffix[];
} __rte_packed;
struct ptp_message {