Add missing check for host_from_stream_offset return value for RAM_SAVE_FLAG_PAGE
Signed-off-by: Orit Wasserman <owasserm@redhat.com>
This commit is contained in:
parent
71ea2e0161
commit
0ff1f9f585
@ -483,6 +483,9 @@ int ram_load(QEMUFile *f, void *opaque, int version_id)
|
|||||||
void *host;
|
void *host;
|
||||||
|
|
||||||
host = host_from_stream_offset(f, addr, flags);
|
host = host_from_stream_offset(f, addr, flags);
|
||||||
|
if (!host) {
|
||||||
|
return -EINVAL;
|
||||||
|
}
|
||||||
|
|
||||||
qemu_get_buffer(f, host, TARGET_PAGE_SIZE);
|
qemu_get_buffer(f, host, TARGET_PAGE_SIZE);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user