mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-23 06:05:27 +00:00
qemuMigrationDstFinishFresh: Avoid multi-line ternary operator in function call
Rewrite the code using a temporary variable. Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
45912ac399
commit
a74fceb7d5
@ -6601,9 +6601,12 @@ qemuMigrationDstFinishFresh(virQEMUDriver *driver,
|
|||||||
*inPostCopy = true;
|
*inPostCopy = true;
|
||||||
|
|
||||||
if (!(flags & VIR_MIGRATE_PAUSED)) {
|
if (!(flags & VIR_MIGRATE_PAUSED)) {
|
||||||
if (qemuProcessStartCPUs(driver, vm,
|
virDomainRunningReason runningReason = VIR_DOMAIN_RUNNING_MIGRATED;
|
||||||
*inPostCopy ? VIR_DOMAIN_RUNNING_POSTCOPY
|
|
||||||
: VIR_DOMAIN_RUNNING_MIGRATED,
|
if (*inPostCopy)
|
||||||
|
runningReason = VIR_DOMAIN_RUNNING_POSTCOPY;
|
||||||
|
|
||||||
|
if (qemuProcessStartCPUs(driver, vm, runningReason,
|
||||||
VIR_ASYNC_JOB_MIGRATION_IN) < 0) {
|
VIR_ASYNC_JOB_MIGRATION_IN) < 0) {
|
||||||
if (virGetLastErrorCode() == VIR_ERR_OK)
|
if (virGetLastErrorCode() == VIR_ERR_OK)
|
||||||
virReportError(VIR_ERR_INTERNAL_ERROR,
|
virReportError(VIR_ERR_INTERNAL_ERROR,
|
||||||
|
Loading…
Reference in New Issue
Block a user