projects
/
qemu.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a915f4b
)
aio: test node->deleted before calling io_flush
author
Paolo Bonzini
<pbonzini@redhat.com>
Wed, 26 Sep 2012 13:21:36 +0000
(15:21 +0200)
committer
Paolo Bonzini
<pbonzini@redhat.com>
Tue, 30 Oct 2012 08:30:53 +0000
(09:30 +0100)
Otherwise, there could be a case where io_flush accesses freed
memory because it should not have been called.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
aio.c
patch
|
blob
|
history
diff --git
a/aio.c
b/aio.c
index c89f1e95c1f50c6bafa96cc2c9d432092b3f898a..734d2cfa0b5d3d8c866fca58abf5abe93a1c3759 100644
(file)
--- a/
aio.c
+++ b/
aio.c
@@
-122,7
+122,7
@@
bool aio_wait(AioContext *ctx)
* Otherwise, if there are no AIO requests, qemu_aio_wait() would
* wait indefinitely.
*/
- if (node->io_flush) {
+ if (
!node->deleted &&
node->io_flush) {
if (node->io_flush(node->opaque) == 0) {
continue;
}