From 9518d68d9aca73fd3794bffd38553d59af013143 Mon Sep 17 00:00:00 2001 From: Denis Kenzior Date: Fri, 28 May 2021 10:57:11 -0500 Subject: [PATCH] eapolutil: Use flexible-array member Instead of zero-length array, use the more preferred flexible-array member. See https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html --- src/eapolutil.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/eapolutil.h b/src/eapolutil.h index 17ea992e..9385248a 100644 --- a/src/eapolutil.h +++ b/src/eapolutil.h @@ -57,7 +57,7 @@ struct eapol_header { struct eapol_frame { struct eapol_header header; - uint8_t data[0]; + uint8_t data[]; } __attribute__ ((packed)); /* gets pointer to MIC */ @@ -111,7 +111,7 @@ struct eapol_key { uint8_t eapol_key_iv[16]; uint8_t key_rsc[8]; uint8_t reserved[8]; - uint8_t key_data[0]; + uint8_t key_data[]; } __attribute__ ((packed)); const struct eapol_key *eapol_key_validate(const uint8_t *frame, size_t len,