[libvirt] [PATCH] util: add missing equal sign in initialization

Daniel P. Berrange berrange at redhat.com
Thu Apr 13 12:23:09 UTC 2017


On Thu, Apr 13, 2017 at 02:14:16PM +0200, Ján Tomko wrote:
> Fix the build with clang:
> util/virperf.c:86:27: error: use of GNU 'missing =' extension
>     in designator [-Werror,-Wgnu-designator]
>     [VIR_PERF_EVENT_MBML] {
>                           ^
>                           =

Fun, I'm suprised gcc allowed this syntax !

> ---
>  src/util/virperf.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> Pushed.
> 
> diff --git a/src/util/virperf.c b/src/util/virperf.c
> index 9ac27c1..fa5b6cc 100644
> --- a/src/util/virperf.c
> +++ b/src/util/virperf.c
> @@ -83,7 +83,7 @@ static struct virPerfEventAttr attrs[] = {
>          .attrType = 0,
>          .attrConfig = 2
>      },
> -    [VIR_PERF_EVENT_MBML] {
> +    [VIR_PERF_EVENT_MBML] = {
>          .attrType = 0,
>          .attrConfig = 3
>      },
> -- 
> 2.10.2
> 
> --
> libvir-list mailing list
> libvir-list at redhat.com
> https://www.redhat.com/mailman/listinfo/libvir-list

Regards,
Daniel
-- 
|: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org              -o-             http://virt-manager.org :|
|: http://entangle-photo.org       -o-    http://search.cpan.org/~danberr/ :|




More information about the libvir-list mailing list