From nobody Mon Feb 9 08:27:59 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) client-ip=216.205.24.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=fail(p=none dis=none) header.from=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1600240710; cv=none; d=zohomail.com; s=zohoarc; b=VjS/oj14gyWA9Dg7iLdizw9Ev/DxbapNGijUfowiEjvh5eyo+aaC+ovzk86e33GY/QNHQnBpeEIRTaSI78i0PomwNXdc0AnfGApTdmHaB6CYDLMP4p2wgwNj9qtrttqU8pchMxx+t3Uu9KvgscClThVtwJ63+127bRdoELAk1Dc= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1600240710; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=2Q/x0iNsUefpIQ81amgfBtwhBOBfj1fy4ENyHbegK0s=; b=MgYjkPaluCHSDNAzPY/GIk/OyWfEvJy9JBT0gxX5xy0X5d88DlZR3uy707F3XMKOlJD2uHzyYe2TfEJhYegr36/+Elf7t2uicjZADPVtyfdHDcygu0S6BalcYj+iDotBuhZOkJk9A+TLIAYSXqEeni1MTrknG93S8GRpfwWOPyA= ARC-Authentication-Results: i=1; mx.zohomail.com; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by mx.zohomail.com with SMTPS id 1600240710414752.8066848022169; Wed, 16 Sep 2020 00:18:30 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-475-iwxhZY3QNKePul_JNaNyjA-1; Wed, 16 Sep 2020 03:18:27 -0400 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id E94AD89CD10; Wed, 16 Sep 2020 07:18:13 +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 963EF1002D52; Wed, 16 Sep 2020 07:18:13 +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 4CB0D44A6A; Wed, 16 Sep 2020 07:18:13 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 08G7I891022928 for ; Wed, 16 Sep 2020 03:18:08 -0400 Received: by smtp.corp.redhat.com (Postfix) id 337602156A2D; Wed, 16 Sep 2020 07:18:08 +0000 (UTC) Received: from mimecast-mx02.redhat.com (mimecast02.extmail.prod.ext.rdu2.redhat.com [10.11.55.18]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 2D3592156A23 for ; Wed, 16 Sep 2020 07:18:05 +0000 (UTC) Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id A27C4801220 for ; Wed, 16 Sep 2020 07:18:05 +0000 (UTC) Received: from mail-wr1-f47.google.com (mail-wr1-f47.google.com [209.85.221.47]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-386-gWx5mp4wNG2sL5vsNwIJiQ-1; Wed, 16 Sep 2020 03:17:59 -0400 Received: by mail-wr1-f47.google.com with SMTP id k15so5706982wrn.10; Wed, 16 Sep 2020 00:17:59 -0700 (PDT) Received: from t440p.suse.asia (60-251-47-115.HINET-IP.hinet.net. [60.251.47.115]) by smtp.gmail.com with ESMTPSA id 9sm3721970wmf.7.2020.09.16.00.17.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 16 Sep 2020 00:17:57 -0700 (PDT) X-MC-Unique: iwxhZY3QNKePul_JNaNyjA-1 X-MC-Unique: gWx5mp4wNG2sL5vsNwIJiQ-1 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=2Q/x0iNsUefpIQ81amgfBtwhBOBfj1fy4ENyHbegK0s=; b=NKqy4E1rlhwzGblswjlIzGWSrlENhTDhocZb4z5fCAZJCp0ntsJC/MqFeNw0XsSXXs KHRaIS6bqmqOGurm8LR25aq28mjS5iABd6voQXuYTcKDYS4vfWXWZXVuAa/6axmsmykB qyPq5nEembWlgRbKYISFADLzm7Hd4+T5ZI2r376/w62fIP7FK7YESJXS4BOMPgWR4Fau Emyq7kP6zPqrxoE6WWg/oTHY/OLL3dTvICCrqJJHBez1XnJvkprFQbx8EVqhZ0WKNoOR 2jUCnWvEQcwnER3DrzFWkmmuQHwvgPM7QDEcY7FbEeRc5bqhMmWwYu6ISUCqFXKqmBSB a9Ow== X-Gm-Message-State: AOAM530y9iU7w0t1wLmwBCO6gqUiewhdHQXhMu3d5TrSnj5vOiNpRAC+ ivySaFfFSSnVbUF+PurugFZdvTfqKaXuSQ== X-Google-Smtp-Source: ABdhPJzXev7WYac8AfOXup+524iR2e87nRadIg6lkJZVEGYyyuXrr/sNsTveVTinwU/rPzZyLJbzWw== X-Received: by 2002:adf:e304:: with SMTP id b4mr24304476wrj.141.1600240677909; Wed, 16 Sep 2020 00:17:57 -0700 (PDT) From: morecache@gmail.com X-Google-Original-From: lma@suse.de To: libvir-list@redhat.com Subject: [libvirt] [PATCH v2 2/4] virsh: event: options --list, --all and --event are mutually exclusive Date: Wed, 16 Sep 2020 15:17:35 +0800 Message-Id: <20200916071737.22938-3-lma@suse.de> In-Reply-To: <20200916071737.22938-1-lma@suse.de> References: <20200916071737.22938-1-lma@suse.de> MIME-Version: 1.0 X-Mimecast-Impersonation-Protect: Policy=CLT - Impersonation Protection Definition; Similar Internal Domain=false; Similar Monitored External Domain=false; Custom External Domain=false; Mimecast External Domain=false; Newly Observed Domain=false; Internal User Name=false; Custom Display Name List=false; Reply-to Address Mismatch=false; Targeted Threat Dictionary=false; Mimecast Threat Dictionary=false; Custom Threat Dictionary=false; X-Scanned-By: MIMEDefang 2.78 on 10.11.54.6 X-loop: libvir-list@redhat.com Cc: jtomko@redhat.com, Lin Ma , eskultet@redhat.com 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: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com X-Mimecast-Spam-Score: 0.002 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" From: Lin Ma Signed-off-by: Lin Ma --- tools/virsh-domain.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tools/virsh-domain.c b/tools/virsh-domain.c index f0ca6f7b83..32edfc0398 100644 --- a/tools/virsh-domain.c +++ b/tools/virsh-domain.c @@ -13710,6 +13710,10 @@ cmdEvent(vshControl *ctl, const vshCmd *cmd) int count =3D 0; virshControlPtr priv =3D ctl->privData; =20 + VSH_EXCLUSIVE_OPTIONS("all", "event"); + VSH_EXCLUSIVE_OPTIONS("list", "all"); + VSH_EXCLUSIVE_OPTIONS("list", "event"); + if (vshCommandOptBool(cmd, "list")) { for (event =3D 0; event < VIR_DOMAIN_EVENT_ID_LAST; event++) vshPrint(ctl, "%s\n", virshDomainEventCallbacks[event].name); --=20 2.26.0