mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-24 22:55:23 +00:00
conf: Use virTristateXXX in virDomainNetDef
Signed-off-by: Tim Wiederhake <twiederh@redhat.com> Reviewed-by: Peter Krempa <pkrempa@redhat.com>
This commit is contained in:
parent
f1d4cd5ab3
commit
6609b64701
@ -10877,15 +10877,16 @@ virDomainNetDefParseXML(virDomainXMLOption *xmlopt,
|
||||
def->type = VIR_DOMAIN_NET_TYPE_USER;
|
||||
}
|
||||
|
||||
trustGuestRxFilters = virXMLPropString(node, "trustGuestRxFilters");
|
||||
if (trustGuestRxFilters &&
|
||||
((def->trustGuestRxFilters
|
||||
= virTristateBoolTypeFromString(trustGuestRxFilters)) <= 0)) {
|
||||
if ((trustGuestRxFilters = virXMLPropString(node, "trustGuestRxFilters"))) {
|
||||
int value;
|
||||
if ((value = virTristateBoolTypeFromString(trustGuestRxFilters)) <= 0) {
|
||||
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
|
||||
_("unknown trustGuestRxFilters value '%s'"),
|
||||
trustGuestRxFilters);
|
||||
goto error;
|
||||
}
|
||||
def->trustGuestRxFilters = value;
|
||||
}
|
||||
|
||||
cur = node->children;
|
||||
while (cur != NULL) {
|
||||
|
@ -1103,7 +1103,7 @@ struct _virDomainNetDef {
|
||||
GHashTable *filterparams;
|
||||
virNetDevBandwidth *bandwidth;
|
||||
virNetDevVlan vlan;
|
||||
int trustGuestRxFilters; /* enum virTristateBool */
|
||||
virTristateBool trustGuestRxFilters;
|
||||
virTristateBool isolatedPort;
|
||||
int linkstate;
|
||||
unsigned int mtu;
|
||||
|
Loading…
Reference in New Issue
Block a user