提交 31fea865 编写于 作者: P Peter Krempa

qemu: domain: Add helper to access vm->privateData->agent

As in commit 88dc7e0c, the helper can be used in cases where the
function actually does not access anyting in the private data besides
the agent.
上级 80a59b4a
......@@ -1872,6 +1872,18 @@ qemuDomainObjEnterMonitorAsync(virQEMUDriverPtr driver,
}
/**
* qemuDomainGetAgent:
* @vm: domain object
*
* Returns the agent pointer of @vm;
*/
qemuAgentPtr
qemuDomainGetAgent(virDomainObjPtr vm)
{
return (((qemuDomainObjPrivatePtr)(vm->privateData))->agent);
}
/*
* obj must be locked before calling
......
......@@ -298,6 +298,7 @@ int qemuDomainObjEnterMonitorAsync(virQEMUDriverPtr driver,
ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(2) ATTRIBUTE_RETURN_CHECK;
qemuAgentPtr qemuDomainGetAgent(virDomainObjPtr vm);
void qemuDomainObjEnterAgent(virDomainObjPtr obj)
ATTRIBUTE_NONNULL(1);
void qemuDomainObjExitAgent(virDomainObjPtr obj)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册