From nobody Thu Apr 18 03:51:24 2024 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 ARC-Seal: i=1; a=rsa-sha256; t=1565901832; cv=none; d=zoho.com; s=zohoarc; b=ky9JsZRmDMCqOrHHJOitxwCsBvGer4smY4FmzP4NIaK4l/f99rN+f/3ew1MTH9YTpPP9VuB6Lw984kp+CsQNIEma/CrrxpXA20Uh/SHVnM7W35W7CxU4Q6ZyfWi23kl8Cj/5WN/sdGL56KYGwNdKtbNknyQMCPNJMYJPRCg5WQI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1565901832; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To:ARC-Authentication-Results; bh=J28DMjLFrMeVqhEShOvAB5M7t7BWfinKDBF8SlixQbM=; b=goXbV6TuZYiMWDgiJ3+ZOM6k9L7AI57RuMvGpnGoyc76mAreNuf+rZo/j49fACpa40u2H1Ts3/WT7nry45NSB2w81lCASsTjKkc8oin0/NkLYGyPlm1bW3VfZeV0vkLIgtnPE0eXcO0QYbRZBTKMQqCqocvEWOj4QSmzM2OR5i8= ARC-Authentication-Results: i=1; mx.zoho.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 header.from= (p=none dis=none) header.from= Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1565901832179786.2011973711229; Thu, 15 Aug 2019 13:43:52 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 0720C2C9700; Thu, 15 Aug 2019 20:43:50 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 8211183881; Thu, 15 Aug 2019 20:43:49 +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 18C8F24BC3; Thu, 15 Aug 2019 20:43:46 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id x7FKgSA6020783 for ; Thu, 15 Aug 2019 16:42:28 -0400 Received: by smtp.corp.redhat.com (Postfix) id 064BD17B64; Thu, 15 Aug 2019 20:42:28 +0000 (UTC) Received: from vhost2.laine.org (ovpn-117-27.phx2.redhat.com [10.3.117.27]) by smtp.corp.redhat.com (Postfix) with ESMTP id A32A38CBB2; Thu, 15 Aug 2019 20:42:25 +0000 (UTC) From: Laine Stump To: libvir-list@redhat.com Date: Thu, 15 Aug 2019 16:42:20 -0400 Message-Id: <20190815204220.21995-1-laine@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-loop: libvir-list@redhat.com Cc: yalzhang@redhat.com Subject: [libvirt] [PATCH] access: fix incorrect addition to virAccessPermNetwork 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: , 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.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.29]); Thu, 15 Aug 2019 20:43:51 +0000 (UTC) Content-Type: text/plain; charset="utf-8" Commit e69444e17 (first appeared in libvirt-5.5.0) added the new value "VIR_ACCESS_PERM_NETWORK_SEARCH_PORTS" to the virAccessPerNetwork enum, and also the string "search_ports" to the VIR_ENUM_IMPL() macro for that enum. Unfortunately, the enum value was added in the middle of the list, while the string was added to the end of the VIR_ENUM_IMPL(). This patch corrects that error by moving the new value to the end of the enum definition, so that the order matches that of the string list. Resolves: https://bugzilla.redhat.com/1741428 Signed-off-by: Laine Stump Reviewed-by: Michal Privoznik --- src/access/viraccessperm.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/access/viraccessperm.h b/src/access/viraccessperm.h index a42512d5e0..7480ee8c2f 100644 --- a/src/access/viraccessperm.h +++ b/src/access/viraccessperm.h @@ -410,18 +410,18 @@ typedef enum { */ VIR_ACCESS_PERM_NETWORK_START, =20 - /** - * @desc: List network ports - * @message: Listing network ports requires authorization - */ - VIR_ACCESS_PERM_NETWORK_SEARCH_PORTS, - /** * @desc: Stop network * @message: Stopping network requires authorization */ VIR_ACCESS_PERM_NETWORK_STOP, =20 + /** + * @desc: List network ports + * @message: Listing network ports requires authorization + */ + VIR_ACCESS_PERM_NETWORK_SEARCH_PORTS, + VIR_ACCESS_PERM_NETWORK_LAST } virAccessPermNetwork; =20 --=20 2.21.0 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list