From: Vincent Minet Date: Tue, 5 Oct 2010 00:23:12 +0000 (+0200) Subject: acpi: Fix an infinite loop in acpi_table_add X-Git-Tag: v0.14.0-rc0~585 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=b755a4289ea6ab881c63b52c4f7f849edd93a232;p=thirdparty%2Fqemu.git acpi: Fix an infinite loop in acpi_table_add Commit d729bb9a7700e364b1c5f9893d61f07a9e002bce has a typo, causing an infinite loop in acpi_table_add. Signed-off-by: Vincent Minet Acked-by: Jes Sorensen Signed-off-by: Blue Swirl --- diff --git a/hw/acpi.c b/hw/acpi.c index 069e05fc7a8..8071e7bebaf 100644 --- a/hw/acpi.c +++ b/hw/acpi.c @@ -161,7 +161,7 @@ int acpi_table_add(const char *t) /* off < length is necessary because file size can be changed under our foot */ - while(s.st_size && off < length); { + while(s.st_size && off < length) { int r; r = read(fd, p + off, s.st_size); if (r > 0) {