g_clear_pointer(&job->ownerAPI, g_free);
job->started = 0;
}
+
+void
+virDomainObjResetAgentJob(virDomainJobObj *job)
+{
+ job->agentActive = VIR_AGENT_JOB_NONE;
+ job->agentOwner = 0;
+ g_clear_pointer(&job->agentOwnerAPI, g_free);
+ job->agentStarted = 0;
+}
}
-static void
-qemuDomainObjResetAgentJob(virDomainJobObj *job)
-{
- job->agentActive = VIR_AGENT_JOB_NONE;
- job->agentOwner = 0;
- g_clear_pointer(&job->agentOwnerAPI, g_free);
- job->agentStarted = 0;
-}
-
-
static void
qemuDomainObjResetAsyncJob(virDomainJobObj *job)
{
}
if (agentJob) {
- qemuDomainObjResetAgentJob(&priv->job);
+ virDomainObjResetAgentJob(&priv->job);
VIR_DEBUG("Started agent job: %s (vm=%p name=%s job=%s async=%s)",
virDomainAgentJobTypeToString(agentJob),
virDomainAsyncJobTypeToString(priv->job.asyncJob),
obj, obj->def->name);
- qemuDomainObjResetAgentJob(&priv->job);
+ virDomainObjResetAgentJob(&priv->job);
/* We indeed need to wake up ALL threads waiting because
* grabbing a job requires checking more variables. */
virCondBroadcast(&priv->job.cond);