diff options
author | Elyes Haouas <ehaouas@noos.fr> | 2023-07-28 06:16:27 +0200 |
---|---|---|
committer | Elyes Haouas <ehaouas@noos.fr> | 2023-07-30 09:59:00 +0000 |
commit | c1700e02faa06eea6be557b8c6a8067bdb24105c (patch) | |
tree | b59ab411f5841dba57568eae8b474a2b4fdd4b1c /src/commonlib | |
parent | 8c0168ab86310eca6f78ba8bcbdf13397951c63e (diff) |
commonlib/fsp_relocate.c: Use C99 flexible arrays
Use C99 flexible arrays instead of older style of one-element or
zero-length arrays.
It allows the compiler to generate errors when the flexible array does
not occur at the end in the structure.
Change-Id: I52b5a83e7e484889bfef5a4e45a0279fadd58890
Signed-off-by: Elyes Haouas <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76784
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Diffstat (limited to 'src/commonlib')
-rw-r--r-- | src/commonlib/fsp_relocate.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/commonlib/fsp_relocate.c b/src/commonlib/fsp_relocate.c index c2c3811ace..c7c4b5a9ef 100644 --- a/src/commonlib/fsp_relocate.c +++ b/src/commonlib/fsp_relocate.c @@ -55,7 +55,7 @@ struct fsp_patch_table { uint8_t header_revision; uint8_t reserved; uint32_t patch_entry_num; - uint32_t patch_entries[0]; + uint32_t patch_entries[]; } __packed; #define FSPP_SIG 0x50505346 |