From: Osier Yang Date: Wed, 22 May 2013 12:05:21 +0000 (+0800) Subject: storage_conf: Improve error messages X-Git-Tag: v1.0.6-rc2~9 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ec2b81c68b5147daeb2f00149d7cff954e99ff5f;p=thirdparty%2Flibvirt.git storage_conf: Improve error messages virStoragePoolDefParseSource: * Better error message virStoragePoolObjLoad: * Break the line line --- diff --git a/src/conf/storage_conf.c b/src/conf/storage_conf.c index d216257357..b9215220ee 100644 --- a/src/conf/storage_conf.c +++ b/src/conf/storage_conf.c @@ -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;