提交 7444ccce 编写于 作者: J Jiri Denemark

qemu: Revert to blocking behavior of qemuAgentCommand

Before commit 05447e3a, qemuAgentCommand
blocked until it got a reply or appropriate event. When new parameter
was added to qemuAgentCommand in the above commit, all existing callers
of it were updated in a wrong way changing them from blocking to
5-seconds timeout.
上级 e360a960
......@@ -1296,7 +1296,7 @@ int qemuAgentShutdown(qemuAgentPtr mon,
mon->await_event = QEMU_AGENT_EVENT_SHUTDOWN;
ret = qemuAgentCommand(mon, cmd, &reply,
VIR_DOMAIN_QEMU_AGENT_COMMAND_DEFAULT);
VIR_DOMAIN_QEMU_AGENT_COMMAND_BLOCK);
if (reply && ret == 0)
ret = qemuAgentCheckError(cmd, reply);
......@@ -1329,7 +1329,7 @@ int qemuAgentFSFreeze(qemuAgentPtr mon)
return -1;
if (qemuAgentCommand(mon, cmd, &reply,
VIR_DOMAIN_QEMU_AGENT_COMMAND_DEFAULT) < 0 ||
VIR_DOMAIN_QEMU_AGENT_COMMAND_BLOCK) < 0 ||
qemuAgentCheckError(cmd, reply) < 0)
goto cleanup;
......@@ -1367,7 +1367,7 @@ int qemuAgentFSThaw(qemuAgentPtr mon)
return -1;
if (qemuAgentCommand(mon, cmd, &reply,
VIR_DOMAIN_QEMU_AGENT_COMMAND_DEFAULT) < 0 ||
VIR_DOMAIN_QEMU_AGENT_COMMAND_BLOCK) < 0 ||
qemuAgentCheckError(cmd, reply) < 0)
goto cleanup;
......@@ -1405,7 +1405,7 @@ qemuAgentSuspend(qemuAgentPtr mon,
mon->await_event = QEMU_AGENT_EVENT_SUSPEND;
ret = qemuAgentCommand(mon, cmd, &reply,
VIR_DOMAIN_QEMU_AGENT_COMMAND_DEFAULT);
VIR_DOMAIN_QEMU_AGENT_COMMAND_BLOCK);
if (reply && ret == 0)
ret = qemuAgentCheckError(cmd, reply);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册