提交 a2374edf 编写于 作者: J Jiri Denemark

qemu: Do not report completed stats until the job finishes

We would happily report and free statistics of a completed migration
even before it actually completed (on the source host while migration is
in the Finish phase).
Signed-off-by: NJiri Denemark <jdenemar@redhat.com>
上级 cb483a68
...@@ -13016,7 +13016,9 @@ qemuDomainGetJobStatsInternal(virQEMUDriverPtr driver, ...@@ -13016,7 +13016,9 @@ qemuDomainGetJobStatsInternal(virQEMUDriverPtr driver,
goto cleanup; goto cleanup;
} }
if (completed) if (completed && priv->job.current)
info = NULL;
else if (completed)
info = priv->job.completed; info = priv->job.completed;
else else
info = priv->job.current; info = priv->job.current;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册