Re: [PATCH 2/6] virDomain{Get, Set}PerfEvents: Add @flags argument

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Mar 31, 2016 at 07:28:57 +0200, Michal Privoznik wrote:
> I've noticed that these APIs are missing @flags argument. Even
> though we don't have a use for them, it's our policy that every
> new API must have @flags.
> 
> Signed-off-by: Michal Privoznik <mprivozn@xxxxxxxxxx>
> ---
>  daemon/remote.c                  |  2 +-
>  include/libvirt/libvirt-domain.h |  6 ++++--
>  src/driver-hypervisor.h          |  6 ++++--
>  src/libvirt-domain.c             | 22 ++++++++++++++--------
>  src/qemu/qemu_driver.c           | 11 ++++++++---
>  src/remote/remote_driver.c       |  4 +++-
>  src/remote/remote_protocol.x     |  2 ++
>  tools/virsh-domain.c             |  5 +++--
>  8 files changed, 39 insertions(+), 19 deletions(-)
> 


>  struct remote_domain_get_perf_events_ret {
> diff --git a/tools/virsh-domain.c b/tools/virsh-domain.c
> index cda442d..a105268 100644
> --- a/tools/virsh-domain.c
> +++ b/tools/virsh-domain.c
> @@ -8610,6 +8610,7 @@ cmdPerf(vshControl *ctl, const vshCmd *cmd)
>      virTypedParameterPtr params = NULL;
>      bool ret = false;
>      const char *enable = NULL, *disable = NULL;
> +    unsigned int flags = VIR_DOMAIN_AFFECT_CURRENT;

There is no such flag option currently, you should pass 0. (I know that
VIR_DOMAIN_AFFECT_CURRENT is actually equal to 0, but in the context of
this patch you are stating that there are no supported flags.)

>  
>      if (!(dom = virshCommandOptDomain(ctl, cmd, NULL)))
>          return false;

ACK, disregard my above statement. Fixing the 'unpleasant' code is more
important at this point.

Peter

Attachment: signature.asc
Description: Digital signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]