mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-12-11 16:00:50 -07:00
savevm: fix wrong initialization by ram_control_load_hook
It should set negative error value rather than 0 in QEMUFile if there has been an error. Reviewed-by: Michael R. Hines <mrhines@us.ibm.com> Signed-off-by: Lei Li <lilei@linux.vnet.ibm.com> Signed-off-by: Juan Quintela <quintela@redhat.com>
This commit is contained in:
parent
675fd0a7da
commit
c77a5f2daa
1 changed files with 1 additions and 1 deletions
2
savevm.c
2
savevm.c
|
|
@ -649,7 +649,7 @@ void ram_control_after_iterate(QEMUFile *f, uint64_t flags)
|
|||
|
||||
void ram_control_load_hook(QEMUFile *f, uint64_t flags)
|
||||
{
|
||||
int ret = 0;
|
||||
int ret = -EINVAL;
|
||||
|
||||
if (f->ops->hook_ram_load) {
|
||||
ret = f->ops->hook_ram_load(f, f->opaque, flags);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue