qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH] aio-win32: fix uninitialized use of have_select


From: Fam Zheng
Subject: Re: [Qemu-devel] [PATCH] aio-win32: fix uninitialized use of have_select_revents
Date: Mon, 15 Sep 2014 10:36:43 +0800
User-agent: Mutt/1.5.23 (2014-03-12)

On Fri, 09/12 12:08, Paolo Bonzini wrote:
> Always initialize it with the return value of aio_prepare.
> 
> Reported-by: TeLeMan <address@hidden>
> Signed-off-by: Paolo Bonzini <address@hidden>
> ---
>  aio-win32.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/aio-win32.c b/aio-win32.c
> index 61e3d2d..7daeae1 100644
> --- a/aio-win32.c
> +++ b/aio-win32.c
> @@ -283,9 +283,9 @@ bool aio_poll(AioContext *ctx, bool blocking)
>      int count;
>      int timeout;
>  
> -    if (aio_prepare(ctx)) {
> +    have_select_revents = aio_prepare(ctx);
> +    if (have_select_revents) {
>          blocking = false;
> -        have_select_revents = true;
>      }
>  
>      was_dispatching = ctx->dispatching;
> -- 
> 2.1.0
> 

Reviewed-by: Fam Zheng <address@hidden>



reply via email to

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