Message ID | 20240129071854.61205-1-ivan.hu@canonical.com |
---|---|
State | Accepted |
Headers | show |
Series | acpi: ras2: stop for loop when list exceeds the table | expand |
diff --git a/src/acpi/ras2/ras2.c b/src/acpi/ras2/ras2.c index 2c604796..a6f42c1e 100644 --- a/src/acpi/ras2/ras2.c +++ b/src/acpi/ras2/ras2.c @@ -50,7 +50,7 @@ static int ras2_test1(fwts_framework *fw) fwts_failed(fw, LOG_LEVEL_HIGH, "RAS2TooShort", "RAS2 table too short, PCC descriptor list exceeds the table."); passed = false; - break; + return FWTS_OK; } fwts_acpi_ras2_pcc_desc *pcc_desc = (fwts_acpi_ras2_pcc_desc *)(table->data + offset); fwts_log_info_verbatim(fw, " PCC Descriptor List:");
Just return the function when the PCC descriptor list exceeds the table. Signed-off-by: Ivan Hu <ivan.hu@canonical.com> --- src/acpi/ras2/ras2.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)