programmer_table: remove null termination
The {0} object at the end of programmer_table which corresponds
to PROGRAMMER_INVALID has no use in current code.
Change-Id: Ib63c2d2941f23a0788e26e5a5feb25d8669acb42
Signed-off-by: Thomas Heijligen <thomas.heijligen@secunet.de>
Original-Reviewed-on: https://review.coreboot.org/c/flashrom/+/55115
Original-Reviewed-by: Nico Huber <nico.h@gmx.de>
Reviewed-on: https://review.coreboot.org/c/flashrom-stable/+/71366
Reviewed-by: Nico Huber <nico.h@gmx.de>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
diff --git a/flashrom.c b/flashrom.c
index 9b9c2fc..59a2739 100644
--- a/flashrom.c
+++ b/flashrom.c
@@ -472,8 +472,6 @@
.delay = internal_delay,
},
#endif
-
- {0}, /* This entry corresponds to PROGRAMMER_INVALID. */
};
#define SHUTDOWN_MAXFN 32
@@ -2070,7 +2068,7 @@
/* Safety check. Instead of aborting after the first error, check
* if more errors exist.
*/
- if (ARRAY_SIZE(programmer_table) - 1 != PROGRAMMER_INVALID) {
+ if (ARRAY_SIZE(programmer_table) != PROGRAMMER_INVALID) {
msg_gerr("Programmer table miscompilation!\n");
ret = 1;
}