aboutsummaryrefslogtreecommitdiff
path: root/tests/test-aio.c
diff options
context:
space:
mode:
authorKevin Wolf <kwolf@redhat.com>2015-11-23 13:30:23 +0100
committerKevin Wolf <kwolf@redhat.com>2015-11-25 14:27:43 +0100
commit7595ed743914b9de1d146213dedc1e007283f723 (patch)
tree0f32688943ecbaca044c0b94f175f93f93d528d5 /tests/test-aio.c
parent5e41fbffa115608fe6f7159d345d6caa0019e687 (diff)
downloadqemu-7595ed743914b9de1d146213dedc1e007283f723.zip
qemu-7595ed743914b9de1d146213dedc1e007283f723.tar.gz
qemu-7595ed743914b9de1d146213dedc1e007283f723.tar.bz2
test-aio: Fix event notifier cleanup
One test case closed an event notifier (event_notifier_cleanup()) without first disabling it (set_event_notifier(..., NULL)). This resulted in a leftover handle 0 that was added to each subsequent WaitForMultipleObjects() call, causing the function to fail (invalid handle). Signed-off-by: Kevin Wolf <kwolf@redhat.com> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'tests/test-aio.c')
-rw-r--r--tests/test-aio.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/tests/test-aio.c b/tests/test-aio.c
index 1623803..e188d8c 100644
--- a/tests/test-aio.c
+++ b/tests/test-aio.c
@@ -393,6 +393,7 @@ static void test_aio_external_client(void)
aio_enable_external(ctx);
}
assert(aio_poll(ctx, false));
+ set_event_notifier(ctx, &data.e, NULL);
event_notifier_cleanup(&data.e);
}
}