提交 09d37bde 编写于 作者: E Eduardo Otubo 提交者: Matthias Bolte

PHYP: Bad comparison when checking for existing domain name

When creating a new domain from XML, the check for an existing
domain name should compare the return of the function to a valid
LPAR ID (!= -1) and not to error (== -1).
上级 e1bd99ab
......@@ -3759,7 +3759,7 @@ phypDomainCreateAndStart(virConnectPtr conn,
goto err;
/* checking if this name already exists on this system */
if (phypGetLparID(session, managed_system, def->name, conn) == -1) {
if (phypGetLparID(session, managed_system, def->name, conn) != -1) {
VIR_WARN0("LPAR name already exists.");
goto err;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册