Am 13.04.2014 23:55, schrieb Igor Mammedov: > Fix typo in build_append_int() which causes integer > truncation when it's in range 0x{F-1}FFFF by packing it > as WordConst instead of required DWordConst. > > Signed-off-by: Igor Mammedov <imamm...@redhat.com> > --- > hw/i386/acpi-build.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c > index 748e866..c3321b5 100644 > --- a/hw/i386/acpi-build.c > +++ b/hw/i386/acpi-build.c > @@ -474,7 +474,7 @@ static void build_append_int(GArray *table, uint32_t > value) > build_append_byte(table, 0x01); /* OneOp */ > } else if (value <= 0xFF) { > build_append_value(table, value, 1); > - } else if (value <= 0xFFFFF) { > + } else if (value <= 0xFFFF) { > build_append_value(table, value, 2); > } else { > build_append_value(table, value, 4); >
Reviewed-by: Stefan Weil <s...@weilnetz.de>