mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 05:35:25 +00:00
qemu: domain: Pass 'qemuCaps' to post parse callbacks when parsing status XML
When status XML was parsed the post-parse callbacks could not access qemu caps and potentially upgrade the definition according to the present caps. Implement the callback to pass it in. Signed-off-by: Peter Krempa <pkrempa@redhat.com>
This commit is contained in:
parent
ac6f736ed1
commit
1bbb5dddbb
@ -2801,6 +2801,15 @@ qemuDomainObjPrivateXMLParse(xmlXPathContextPtr ctxt,
|
||||
}
|
||||
|
||||
|
||||
static void *
|
||||
qemuDomainObjPrivateXMLGetParseOpaque(virDomainObjPtr vm)
|
||||
{
|
||||
qemuDomainObjPrivatePtr priv = vm->privateData;
|
||||
|
||||
return priv->qemuCaps;
|
||||
}
|
||||
|
||||
|
||||
virDomainXMLPrivateDataCallbacks virQEMUDriverPrivateDataCallbacks = {
|
||||
.alloc = qemuDomainObjPrivateAlloc,
|
||||
.free = qemuDomainObjPrivateFree,
|
||||
@ -2809,6 +2818,7 @@ virDomainXMLPrivateDataCallbacks virQEMUDriverPrivateDataCallbacks = {
|
||||
.chrSourceNew = qemuDomainChrSourcePrivateNew,
|
||||
.parse = qemuDomainObjPrivateXMLParse,
|
||||
.format = qemuDomainObjPrivateXMLFormat,
|
||||
.getParseOpaque = qemuDomainObjPrivateXMLGetParseOpaque,
|
||||
.storageParse = qemuStorageSourcePrivateDataParse,
|
||||
.storageFormat = qemuStorageSourcePrivateDataFormat,
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user