Re: [Qemu-devel] [PATCH] Fix piix4_pm savevm buffer overflow.

2012-11-09 Thread Paolo Bonzini
Il 08/11/2012 19:21, Gerd Hoffmann ha scritto: > vmstate will read/write 8 bytes for the gpe bits, whereas only two bytes > are allocated (and used). So make sure we allocate enougth to not > overrun the buffer on savevm and loadvm. > > Fixing vmstate would probably be better but that has the unp

[Qemu-devel] [PATCH] Fix piix4_pm savevm buffer overflow.

2012-11-08 Thread Gerd Hoffmann
vmstate will read/write 8 bytes for the gpe bits, whereas only two bytes are allocated (and used). So make sure we allocate enougth to not overrun the buffer on savevm and loadvm. Fixing vmstate would probably be better but that has the unpleasent side effect of breaking migration. Signed-off-by