提交 5534e4e6 编写于 作者: X Xu Yandong 提交者: Andrea Bolognani

virsh: Fix return code for dump

After the commit dc0771cf, ret variable no longer
represents the status of the return code, use
data->ret replace it.
Signed-off-by: NXu Yandong <xuyandong2@huawei.com>
Reviewed-by: NAndrea Bolognani <abologna@redhat.com>
Reviewed-by: NDaniel P. Berrangé <berrange@redhat.com>
Reviewed-by: NMichal Privoznik <mprivozn@redhat.com>
上级 7b0f4634
......@@ -5522,7 +5522,6 @@ static bool
cmdDump(vshControl *ctl, const vshCmd *cmd)
{
virDomainPtr dom;
bool ret = false;
bool verbose = false;
const char *name = NULL;
const char *to = NULL;
......@@ -5556,12 +5555,12 @@ cmdDump(vshControl *ctl, const vshCmd *cmd)
virThreadJoin(&workerThread);
if (!ret)
if (!data.ret)
vshPrintExtra(ctl, _("\nDomain %s dumped to %s\n"), name, to);
cleanup:
virshDomainFree(dom);
return !ret;
return !data.ret;
}
static const vshCmdInfo info_screenshot[] = {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册