]> Git Repo - qemu.git/commitdiff
aio-win32: fix uninitialized use of have_select_revents
authorPaolo Bonzini <[email protected]>
Fri, 12 Sep 2014 10:08:49 +0000 (12:08 +0200)
committerStefan Hajnoczi <[email protected]>
Mon, 22 Sep 2014 10:38:50 +0000 (11:38 +0100)
Always initialize it with the return value of aio_prepare.

Reported-by: TeLeMan <[email protected]>
Signed-off-by: Paolo Bonzini <[email protected]>
Reviewed-by: Stefan Hajnoczi <[email protected]>
Reviewed-by: Fam Zheng <[email protected]>
Signed-off-by: Stefan Hajnoczi <[email protected]>
aio-win32.c

index 61e3d2ddfe900bf90f47022a85996dbcc038aa47..7daeae18f14dae58dd8e5d98bab9f0e81a5038b4 100644 (file)
@@ -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;
This page took 0.026345 seconds and 4 git commands to generate.