Re: [PATCH virt-viewer 4/4] Fix missing field initializers

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

 



On 06/23/2016 10:26 AM, Pavel Grunt wrote:
> On Thu, 2016-06-23 at 10:15 -0300, Eduardo Lima (Etrunko) wrote:
>> On 06/22/2016 05:16 PM, Pavel Grunt wrote:
>>> On Wed, 2016-06-22 at 14:59 -0300, Eduardo Lima (Etrunko) wrote:
>>>> This is not actually necessary as of C99. You only need to initialize
>>>> any field of a structure to get all other fields initialized too.
>>>
>>> yes, I was just annoyed by the warning..
>>
>>
>> Interesting, can you share what was exactly the warning message? Clang
>> as a modern compiler should be able to handle this case.
>>
> 
> virt-viewer-window.c:1164:31: warning: missing field 'accel_mods' initializer
>       [-Wmissing-field-initializers]
>         GtkAccelKey key = { 0 };
> 
> maybe it is needed to pass something like "--std=c99" to the compiler
> 

I suspect it is because accel_mods is a enum (GdkModifierType) and the
compiler would not know a default value for that one.


-- 
Eduardo de Barros Lima (Etrunko)
Software Engineer - RedHat
etrunko@xxxxxxxxxx

_______________________________________________
virt-tools-list mailing list
virt-tools-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/virt-tools-list



[Index of Archives]     [Linux Virtualization]     [KVM Development]     [CentOS Virtualization]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]     [Video 4 Linux]

  Powered by Linux