mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-09 18:44:58 -06:00
Unlock ramlist lock also in error case
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Juan Quintela <quintela@redhat.com> Reviewed-by: Reviewed-by: Eric Blake <eblake@redhat.com>
This commit is contained in:
parent
47f4dac3fd
commit
fb3409de22
1 changed files with 2 additions and 1 deletions
|
@ -642,12 +642,13 @@ static int ram_save_iterate(QEMUFile *f, void *opaque)
|
||||||
i++;
|
i++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
qemu_mutex_unlock_ramlist();
|
||||||
|
|
||||||
if (ret < 0) {
|
if (ret < 0) {
|
||||||
bytes_transferred += total_sent;
|
bytes_transferred += total_sent;
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
qemu_mutex_unlock_ramlist();
|
|
||||||
qemu_put_be64(f, RAM_SAVE_FLAG_EOS);
|
qemu_put_be64(f, RAM_SAVE_FLAG_EOS);
|
||||||
total_sent += 8;
|
total_sent += 8;
|
||||||
bytes_transferred += total_sent;
|
bytes_transferred += total_sent;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue