Fix crash on resolution change -> screen dump -> vga redraw (Avi Kivity)
commitda95f49a9d0bc9597bd2c4ab5a7ee9bea7c4b01d
authoraliguori <aliguori@c046a42c-6fe2-441c-8c8c-71466251a162>
Fri, 10 Apr 2009 18:36:38 +0000 (10 18:36 +0000)
committeraliguori <aliguori@c046a42c-6fe2-441c-8c8c-71466251a162>
Fri, 10 Apr 2009 18:36:38 +0000 (10 18:36 +0000)
tree26e98439f12ce2998d79e3964cdcd2c1bd87db97
parent06b393452f247f0a8f18674fd7e9dacfb3838924
Fix crash on resolution change -> screen dump -> vga redraw (Avi Kivity)

The vga screen dump function updates last_width and last_height,
but does not change the DisplaySurface that these variables describe.
A consequent vga_draw_graphic() will therefore fail to resize the
surface and crash.

Fix by invalidating the display state after a screen dump, forcing
vga_draw_graphic() to reallocate the DisplaySurface.

Signed-off-by: Avi Kivity <avi@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/branches/stable_0_10@7069 c046a42c-6fe2-441c-8c8c-71466251a162
hw/vga.c