]> rtime.felk.cvut.cz Git - lisovros/qemu_apohw.git/commit
block/linux-aio: fix memory and fd leak
authorStefan Hajnoczi <stefanha@redhat.com>
Thu, 8 May 2014 14:34:48 +0000 (16:34 +0200)
committerStefan Hajnoczi <stefanha@redhat.com>
Wed, 4 Jun 2014 07:56:11 +0000 (09:56 +0200)
commitabd269b7cf1f084a067731acb8f3272c193cb5f0
tree62f15b0771a9e495eb90be2621e0c3df23060c6a
parentc2f3426c9bba0195b15a919587f794b110a2dcfc
block/linux-aio: fix memory and fd leak

Hot unplugging -drive aio=native,file=test.img,format=raw images leaves
the Linux AIO event notifier and struct qemu_laio_state allocated.
Luckily nothing will use the event notifier after the BlockDriverState
has been closed so the handler function is never called.

It's still worth fixing this resource leak.

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
block/linux-aio.c
block/raw-aio.h
block/raw-posix.c