]> git.proxmox.com Git - mirror_qemu.git/commit - migration/qemu-file.c
migration: detect compression and decompression errors
authorXiao Guangrong <xiaoguangrong@tencent.com>
Fri, 30 Mar 2018 07:51:22 +0000 (15:51 +0800)
committerDr. David Alan Gilbert <dgilbert@redhat.com>
Wed, 25 Apr 2018 17:04:08 +0000 (18:04 +0100)
commit34ab9e9743aeaf265929d930747f101fa5c76fea
tree616c81663414a3e84eb881b63dc831e70e528d48
parent797ca154b4c68dbd8e93382f714388ab311f672d
migration: detect compression and decompression errors

Currently the page being compressed is allowed to be updated by
the VM on the source QEMU, correspondingly the destination QEMU
just ignores the decompression error. However, we completely miss
the chance to catch real errors, then the VM is corrupted silently

To make the migration more robuster, we copy the page to a buffer
first to avoid it being written by VM, then detect and handle the
errors of both compression and decompression errors properly

Reviewed-by: Peter Xu <peterx@redhat.com>
Signed-off-by: Xiao Guangrong <xiaoguangrong@tencent.com>
Message-Id: <20180330075128.26919-5-xiaoguangrong@tencent.com>
Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
migration/qemu-file.c
migration/ram.c