[libvirt PATCH 6/8] util: xml: remove function names from error messages

Ján Tomko jtomko at redhat.com
Sat Mar 18 13:38:25 UTC 2023


The function name is already logged, and these can happen only as a
result of a programmer error.

Signed-off-by: Ján Tomko <jtomko at redhat.com>
---
 src/util/virxml.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/util/virxml.c b/src/util/virxml.c
index c0789c062c..a84048e14a 100644
--- a/src/util/virxml.c
+++ b/src/util/virxml.c
@@ -864,7 +864,7 @@ virXPathBoolean(const char *xpath,
 
     if ((ctxt == NULL) || (xpath == NULL)) {
         virReportError(VIR_ERR_INTERNAL_ERROR,
-                       "%s", _("Invalid parameter to virXPathBoolean()"));
+                       "%s", _("Invalid parameter"));
         return -1;
     }
     obj = xmlXPathEval(BAD_CAST xpath, ctxt);
@@ -917,7 +917,7 @@ virXPathNode(const char *xpath,
 
     if ((ctxt == NULL) || (xpath == NULL)) {
         virReportError(VIR_ERR_INTERNAL_ERROR,
-                       "%s", _("Invalid parameter to virXPathNode()"));
+                       "%s", _("Invalid parameter"));
         return NULL;
     }
     obj = xmlXPathEval(BAD_CAST xpath, ctxt);
@@ -952,7 +952,7 @@ virXPathNodeSet(const char *xpath,
 
     if ((ctxt == NULL) || (xpath == NULL)) {
         virReportError(VIR_ERR_INTERNAL_ERROR,
-                       "%s", _("Invalid parameter to virXPathNodeSet()"));
+                       "%s", _("Invalid parameter"));
         return -1;
     }
 
-- 
2.39.2



More information about the libvir-list mailing list