[libvirt PATCH] Set -Wno-incompatible-pointer-types-discards-qualifiers

Ján Tomko jtomko at redhat.com
Thu Nov 12 09:53:01 UTC 2020


On a Thursday in 2020, Daniel P. Berrangé wrote:
>With CLang we're getting failures from cats in GLib macros

s/cats/casts/ :)

>
>../dist-unpack/libvirt-6.10.0/src/util/vireventthread.c:35:1:
>  error: passing 'typeof (*(&g_define_type_id__volatile)) *'
>  (aka 'volatile unsigned long *') to parameter of type
>  'gsize *' (aka 'unsigned long *') discards qualifiers
>  [-Werror,-Wincompatible-pointer-types-discards-qualifiers]
>G_DEFINE_TYPE(virEventThread, vir_event_thread, G_TYPE_OBJECT)
>^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
>The cast is valid and there's no way for libvirt to workaround
>the issue, so we must disable this CLang warning flag.
>
>Signed-off-by: Daniel P. Berrangé <berrange at redhat.com>
>---
> meson.build | 3 +++
> 1 file changed, 3 insertions(+)
>

Reviewed-by: Ján Tomko <jtomko at redhat.com>

Jano
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20201112/e6f5d487/attachment-0001.sig>


More information about the libvir-list mailing list