Use an if/else branch rather than a expression with a ternary operator. Signed-off-by: Peter Krempa <pkrempa@xxxxxxxxxx> --- src/qemu/qemu_snapshot.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index f92b571b06..355a2fd782 100644 --- a/src/qemu/qemu_snapshot.c +++ b/src/qemu/qemu_snapshot.c @@ -1672,9 +1672,10 @@ qemuSnapshotCreateAlignDisks(virDomainObj *vm, return -1; } - def->memory = (def->state == VIR_DOMAIN_SNAPSHOT_SHUTOFF ? - VIR_DOMAIN_SNAPSHOT_LOCATION_NONE : - VIR_DOMAIN_SNAPSHOT_LOCATION_INTERNAL); + if (def->state == VIR_DOMAIN_SNAPSHOT_SHUTOFF) + def->memory = VIR_DOMAIN_SNAPSHOT_LOCATION_NONE; + else + def->memory = VIR_DOMAIN_SNAPSHOT_LOCATION_INTERNAL; } if (virDomainSnapshotAlignDisks(def, NULL, align_location, true) < 0) return -1; -- 2.35.1