From nobody Wed May 14 13:15:05 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1523990437025688.0219834149015; Tue, 17 Apr 2018 11:40:37 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 6349E81DE4; Tue, 17 Apr 2018 18:40:35 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 28A297ED44; Tue, 17 Apr 2018 18:40:35 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id D76A8180BAD3; Tue, 17 Apr 2018 18:40:34 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id w3HIeFuX031801 for ; Tue, 17 Apr 2018 14:40:16 -0400 Received: by smtp.corp.redhat.com (Postfix) id BEDEC200BCCE; Tue, 17 Apr 2018 18:40:15 +0000 (UTC) Received: from worklaptop.bos.redhat.com (dhcp-17-157.bos.redhat.com [10.18.17.157]) by smtp.corp.redhat.com (Postfix) with ESMTP id 90E242023227; Tue, 17 Apr 2018 18:40:15 +0000 (UTC) From: Cole Robinson To: libvirt-list@redhat.com Date: Tue, 17 Apr 2018 14:40:11 -0400 Message-Id: <18601ec4d9e0e022f5d411eb60051114b7b462ab.1523989580.git.crobinso@redhat.com> In-Reply-To: References: In-Reply-To: References: X-Scanned-By: MIMEDefang 2.78 on 10.11.54.4 X-loop: libvir-list@redhat.com Cc: =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= Subject: [libvirt] [PATCH 2/3] conf: Add a comment warning about boolean feature XML X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.25]); Tue, 17 Apr 2018 18:40:35 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" This is the old style and we really shouldn't be adding any more examples like this. Add a comment to warn devs away Signed-off-by: Cole Robinson Reviewed-by: John Ferlan --- docs/schemas/domaincommon.rng | 6 +++++- src/conf/domain_conf.c | 2 ++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/docs/schemas/domaincommon.rng b/docs/schemas/domaincommon.rng index 4cab55f05..015c5b737 100644 --- a/docs/schemas/domaincommon.rng +++ b/docs/schemas/domaincommon.rng @@ -5036,7 +5036,11 @@ =20 - + + + + + =20 diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 648057ad4..e303c503e 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -26871,6 +26871,8 @@ virDomainDefFormatInternal(virDomainDefPtr def, case VIR_DOMAIN_FEATURE_PAE: case VIR_DOMAIN_FEATURE_VIRIDIAN: case VIR_DOMAIN_FEATURE_PRIVNET: + /* NOTE: This is for old style booleans. New XML + * should use the explicit state=3Don|off output below */ switch ((virTristateSwitch) def->features[i]) { case VIR_TRISTATE_SWITCH_ABSENT: break; --=20 2.17.0 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list