提交 ec2b81c6 编写于 作者: O Osier Yang

storage_conf: Improve error messages

virStoragePoolDefParseSource:
  * Better error message

virStoragePoolObjLoad:
  * Break the line line
上级 1c6fe3fa
......@@ -531,7 +531,7 @@ virStoragePoolDefParseSource(xmlXPathContextPtr ctxt,
source->name = virXPathString("string(./name)", ctxt);
if (pool_type == VIR_STORAGE_POOL_RBD && source->name == NULL) {
virReportError(VIR_ERR_XML_ERROR, "%s",
_("missing mandatory 'name' field for RBD pool name"));
_("element 'name' is mandatory for RBD pool"));
goto cleanup;
}
......@@ -1697,7 +1697,8 @@ virStoragePoolObjLoad(virStoragePoolObjListPtr pools,
if (!virFileMatchesNameSuffix(file, def->name, ".xml")) {
virReportError(VIR_ERR_XML_ERROR,
_("Storage pool config filename '%s' does not match pool name '%s'"),
_("Storage pool config filename '%s' does "
"not match pool name '%s'"),
path, def->name);
virStoragePoolDefFree(def);
return NULL;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册