Fix block-vmdk.c:vmdk_close() use-after-free, by Ed Maste.

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4526 c046a42c-6fe2-441c-8c8c-71466251a162
This commit is contained in:
ths 2008-05-22 13:51:48 +00:00
parent 34151a20ea
commit 5cbdd273fb
1 changed files with 1 additions and 1 deletions

View File

@ -808,9 +808,9 @@ static void vmdk_close(BlockDriverState *bs)
qemu_free(s->l1_table);
qemu_free(s->l2_cache);
bdrv_delete(s->hd);
// try to close parent image, if exist
vmdk_parent_close(s->hd);
bdrv_delete(s->hd);
}
static void vmdk_flush(BlockDriverState *bs)