[libvirt] [PATCH 29/30] Remove spaces after casts in rest of the files

Andrea Bolognani abologna at redhat.com
Thu Apr 26 07:43:03 UTC 2018


On Wed, 2018-04-25 at 15:25 +0200, Martin Kletzander wrote:
>  /* Round up to the next closest power of 2. It will return rounded number or 0
>   * for 0 or number more than 2^31 (for 32bit unsigned int). */
>  # define VIR_ROUND_UP_POWER_OF_TWO(value) \
> -    ((value) > 0 && (value) <= 1U << (sizeof(unsigned int) * 8 - 1) ? \
> -     1U << (sizeof(unsigned int) * 8 - count_leading_zeros((value) - 1)) : 0)
> +    ((value) > 0 && (value) <= 1U << (sizeof(unsigned int)* 8 - 1) ? \
> +     1U << (sizeof(unsigned int)* 8 - count_leading_zeros((value) - 1)) : 0)

These are clearly wrong. You're going to have to tune your regex
so that it doesn't mistake sizeof() invocations for casts.

-- 
Andrea Bolognani / Red Hat / Virtualization




More information about the libvir-list mailing list