]> xenbits.xensource.com Git - libvirt.git/commitdiff
virDomainFeaturesDefParse: Add comment warning about features being specified repeatedly
authorPeter Krempa <pkrempa@redhat.com>
Mon, 9 Sep 2024 14:46:06 +0000 (16:46 +0200)
committerPavel Hrdina <phrdina@redhat.com>
Tue, 10 Sep 2024 12:26:24 +0000 (14:26 +0200)
Few of the handlers didn't take that possibility into account. Warn
others.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
src/conf/domain_conf.c

index 0f0488f3a271d225c24ff1f199c3f3a01371036d..cf4b1b2aef011631bcc9d322603235ce6e57c41b 100644 (file)
@@ -16849,6 +16849,8 @@ virDomainFeaturesDefParse(virDomainDef *def,
             return -1;
         }
 
+        /* Beware that users can specify the given feature multiple times, so
+         * the parser must be able to handle that */
         switch ((virDomainFeature) val) {
         case VIR_DOMAIN_FEATURE_ACPI:
         case VIR_DOMAIN_FEATURE_PAE: