{
qemuDomainObjPrivatePtr priv = vm->privateData;
virJSONValuePtr actions = NULL;
+ bool do_transaction = false;
int ret = 0;
size_t i;
bool persist = false;
reuse, asyncJob);
if (ret < 0)
break;
+
+ do_transaction = true;
}
if (actions) {
- if (ret == 0) {
+ if (ret == 0 && do_transaction) {
if (qemuDomainObjEnterMonitorAsync(driver, vm, asyncJob) == 0) {
ret = qemuMonitorTransaction(priv->mon, actions);
if (qemuDomainObjExitMonitor(driver, vm) < 0)
/* failed to enter monitor, clean stuff up and quit */
ret = -1;
}
+ } else {
+ VIR_DEBUG("no disks to snapshot, skipping 'transaction' command");
}
virJSONValueFree(actions);