virNetDevBandwidthParse: Don't validate element name

Callers make sure to pass the correct element.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
Peter Krempa 2023-02-13 14:38:09 +01:00
parent 79b04c9606
commit 92332ade1f

View File

@ -112,12 +112,6 @@ virNetDevBandwidthParse(virNetDevBandwidth **bandwidth,
def = g_new0(virNetDevBandwidth, 1); def = g_new0(virNetDevBandwidth, 1);
if (!node || !virXMLNodeNameEqual(node, "bandwidth")) {
virReportError(VIR_ERR_INVALID_ARG, "%s",
_("invalid argument supplied"));
return -1;
}
class_id_prop = virXMLPropString(node, "classID"); class_id_prop = virXMLPropString(node, "classID");
if (class_id_prop) { if (class_id_prop) {
if (!class_id) { if (!class_id) {