提交 d3121936 编写于 作者: J Jim Fehlig 提交者: Cole Robinson

Check for errors when parsing bridge interface XML

The return status of virInterfaceDefParseBridge() was not being
checked, potentially resulting in the creation of a broken
interface.
(cherry picked from commit cc004a66)
上级 5814e39b
...@@ -769,7 +769,8 @@ virInterfaceDefParseXML(xmlXPathContextPtr ctxt, int parentIfType) { ...@@ -769,7 +769,8 @@ virInterfaceDefParseXML(xmlXPathContextPtr ctxt, int parentIfType) {
} }
def->data.bridge.delay = virXMLPropString(bridge, "delay"); def->data.bridge.delay = virXMLPropString(bridge, "delay");
ctxt->node = bridge; ctxt->node = bridge;
virInterfaceDefParseBridge(def, ctxt); if (virInterfaceDefParseBridge(def, ctxt) < 0)
goto error;
break; break;
} }
case VIR_INTERFACE_TYPE_BOND: { case VIR_INTERFACE_TYPE_BOND: {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册