We want to unify on one block job cancellation API. Use
qemuMonitorBlockJobCancel which has more features.
In case of job refresh, we are killing off any unknown jobs so we don't
care about their fate.
Another difference is that an possible error from the block job
cancellation might be reported, but we don't really care here ince
it's a very unlikely scenario and we also report a warning.
Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
qemuDomainObjEnterMonitor(driver, vm);
- rc = qemuMonitorJobCancel(priv->mon, job->name, true);
+ rc = qemuMonitorBlockJobCancel(priv->mon, job->name, true);
if (rc == -1 && jobinfo[i]->status == QEMU_MONITOR_JOB_STATUS_CONCLUDED)
VIR_WARN("can't cancel job '%s' with invalid data", job->name);