]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
conf: scheduler parser: do not hardcode element name
authorJán Tomko <jtomko@redhat.com>
Sat, 25 Jul 2020 07:49:38 +0000 (09:49 +0200)
committerJán Tomko <jtomko@redhat.com>
Mon, 3 Aug 2020 05:23:45 +0000 (07:23 +0200)
When trying to parse an XML with overlapping iothread scheduler
settings, the error message was rather confusing:

   error: iothreadssched attributes 'vcpus' must not overlap

Pass the correct element name.

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
src/conf/domain_conf.c

index 0f12b5457502520d107ae531f1597a7e6c3e01d0..1179a27a0028ee760d6b88d2b81a9039b5ea1832 100644 (file)
@@ -20024,8 +20024,8 @@ virDomainThreadSchedParseHelper(xmlNodePtr node,
 
         if (sched->policy != VIR_PROC_POLICY_NONE) {
             virReportError(VIR_ERR_XML_DETAIL,
-                           _("'%s' attributes 'vcpus' must not overlap"),
-                           elementName);
+                           _("'%s' attributes '%s' must not overlap"),
+                           elementName, attributeName);
             return -1;
         }