mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-24 22:55:23 +00:00
qemu: domain: Add 'errmsg' field to qemuDomainJobInfo
The field can be used by jobs to add an optional error message to a completed (failed) job. Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com>
This commit is contained in:
parent
4f39774610
commit
75a66f1076
@ -308,6 +308,7 @@ qemuDomainDisableNamespace(virDomainObjPtr vm,
|
|||||||
void
|
void
|
||||||
qemuDomainJobInfoFree(qemuDomainJobInfoPtr info)
|
qemuDomainJobInfoFree(qemuDomainJobInfoPtr info)
|
||||||
{
|
{
|
||||||
|
g_free(info->errmsg);
|
||||||
g_free(info);
|
g_free(info);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -319,6 +320,8 @@ qemuDomainJobInfoCopy(qemuDomainJobInfoPtr info)
|
|||||||
|
|
||||||
memcpy(ret, info, sizeof(*info));
|
memcpy(ret, info, sizeof(*info));
|
||||||
|
|
||||||
|
ret->errmsg = g_strdup(info->errmsg);
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -175,6 +175,8 @@ struct _qemuDomainJobInfo {
|
|||||||
qemuDomainBackupStats backup;
|
qemuDomainBackupStats backup;
|
||||||
} stats;
|
} stats;
|
||||||
qemuDomainMirrorStats mirrorStats;
|
qemuDomainMirrorStats mirrorStats;
|
||||||
|
|
||||||
|
char *errmsg; /* optional error message for failed completed jobs */
|
||||||
};
|
};
|
||||||
|
|
||||||
void
|
void
|
||||||
|
Loading…
Reference in New Issue
Block a user