[5/6] io: annotate fts_name with __decl_is_flex_array

Message ID 20230710150454.5490-6-cristian@rodriguez.im
State New
Headers
Series Support use of -fstrict-flex-arrays in user code |

Checks

Context Check Description
redhat-pt-bot/TryBot-apply_patch success Patch applied to master at the time it was sent
linaro-tcwg-bot/tcwg_glibc_check--master-arm success Testing passed
linaro-tcwg-bot/tcwg_glibc_check--master-aarch64 success Testing passed
linaro-tcwg-bot/tcwg_glibc_build--master-arm success Testing passed
linaro-tcwg-bot/tcwg_glibc_build--master-aarch64 success Testing passed

Commit Message

Cristian Rodríguez July 10, 2023, 3:04 p.m. UTC
  Signed-off-by: Cristian Rodríguez <cristian@rodriguez.im>
---
 io/fts.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
  

Patch

diff --git a/io/fts.h b/io/fts.h
index 493f494e06..dbafebaf1f 100644
--- a/io/fts.h
+++ b/io/fts.h
@@ -143,7 +143,7 @@  typedef struct _ftsent {
 	unsigned short fts_instr;	/* fts_set() instructions */
 
 	struct stat *fts_statp;		/* stat(2) information */
-	char fts_name[1];		/* file name */
+	char fts_name[1] __decl_is_flex_array;	/* file name */
 } FTSENT;
 
 #ifdef __USE_LARGEFILE64
@@ -173,7 +173,7 @@  typedef struct _ftsent64 {
 	unsigned short fts_instr;	/* fts_set() instructions */
 
 	struct stat64 *fts_statp;	/* stat(2) information */
-	char fts_name[1];		/* file name */
+	char fts_name[1] __decl_is_flex_array;	/* file name */
 } FTSENT64;
 #endif