qxl: fix pre-save logic

Oops.  Logic is backwards.

Fixes: 39b8a183e2 ("qxl: remove assert in qxl_pre_save.")
Resolves: https://gitlab.com/qemu-project/qemu/-/issues/610
Resolves: https://bugzilla.redhat.com//show_bug.cgi?id=2002907
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20210910094203.3582378-1-kraxel@redhat.com>
(cherry picked from commit eb94846280)
Signed-off-by: Michael Roth <michael.roth@amd.com>
Gerd Hoffmann 2021-09-10 11:42:03 +02:00 committed by Michael Roth
parent 43583f0c07
commit 34833f361b
1 changed files with 1 additions and 1 deletions

View File

@ -2252,7 +2252,7 @@ static int qxl_pre_save(void *opaque)
} else {
d->last_release_offset = (uint8_t *)d->last_release - ram_start;
}
if (d->last_release_offset < d->vga.vram_size) {
if (d->last_release_offset >= d->vga.vram_size) {
return 1;
}