]> git.ipfire.org Git - thirdparty/libvirt.git/commit
qemu: set jobinfo type to CANCELLED if migration is cancelled in all conditions
authorWang Rui <moon.wangrui@huawei.com>
Mon, 1 Dec 2014 07:05:32 +0000 (15:05 +0800)
committerMartin Kletzander <mkletzan@redhat.com>
Mon, 1 Dec 2014 07:17:24 +0000 (08:17 +0100)
commit0b0cba4dba288792aecf81bea8b87b06ac5acec1
tree27641497b6b403a6148b94de077d37e8d1e8c4bf
parent191b84dc159839d5749f32a5ddf15ad13b227f2f
qemu: set jobinfo type to CANCELLED if migration is cancelled in all conditions

The migration job status is traced in qemuMigrationUpdateJobStatus
which is called in qemuMigrationRun. But if migration is cancelled
before the trace such as in qemuMigrationDriveMirror, the jobinfo
type won't be updated to CANCELLED. After this patch, we can get
jobinfo type CANCELLED if migration is cancelled during drive
mirror.  Moreover, we can't use qemuMigrationUpdateJobStatus
because from qemu's point of view it's just the drive mirror being
cancelled and the migration hasn't even started yet.

Signed-off-by: Wang Rui <moon.wangrui@huawei.com>
src/qemu/qemu_migration.c