qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v3] glib: fix g_poll early timeout on windows


From: Stanislav Vorobiov
Subject: Re: [Qemu-devel] [PATCH v3] glib: fix g_poll early timeout on windows
Date: Wed, 07 May 2014 12:36:25 +0400
User-agent: Mozilla/5.0 (X11; Linux i686; rv:24.0) Gecko/20100101 Thunderbird/24.4.0

Hi,

Hm, but (int)res expression is not unsigned, it's signed. I've also had this 
warning,
but with this expression: (res < WAIT_OBJECT_0), that's why I put (int) there. 
Could it be that
for some reason your compiler treats "int" and "unsigned int", that would be 
really strange though...

On 05/07/2014 12:02 PM, Stefan Hajnoczi wrote:
> On Fri, Apr 18, 2014 at 08:24:03PM +0400, Stanislav Vorobiov wrote:
> 
> Please fix the following compiler warning with gcc 4.8.2:
> 
>> +        } else if ((res == WAIT_TIMEOUT) || (res == WAIT_IO_COMPLETION) ||
>> +                   ((int)res < WAIT_OBJECT_0) ||
>> +                   (res >= (WAIT_OBJECT_0 + nhandles))) {
>> +            break;
>> +        }
> 
> util/oslib-win32.c: In function 'g_poll_fixed':
> util/oslib-win32.c:324:21: warning: comparison of unsigned expression < 0 is 
> always false [-Wtype-limits]
>                     ((int)res < WAIT_OBJECT_0) ||
>                                        ^
> 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]