aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>2004-12-12 11:24:44 +0000
committerbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>2004-12-12 11:24:44 +0000
commit585d0ed98b032cdd062b9d43a6d0ef478fc914e8 (patch)
treef64edb27330258782743ede1525c1af2ec768d78 /block-cloop.c
parentupdated guest kernel patch for qemu-fast (Martin Koniczek) (diff)
downloadqemu-kvm-585d0ed98b032cdd062b9d43a6d0ef478fc914e8.tar.gz
qemu-kvm-585d0ed98b032cdd062b9d43a6d0ef478fc914e8.tar.bz2
qemu-kvm-585d0ed98b032cdd062b9d43a6d0ef478fc914e8.zip
.dmg disk image format support (Johannes Schindelin)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1171 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'block-cloop.c')
-rw-r--r--block-cloop.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/block-cloop.c b/block-cloop.c
index f22253daa..de9085538 100644
--- a/block-cloop.c
+++ b/block-cloop.c
@@ -1,5 +1,5 @@
/*
- * QEMU System Emulator block driver
+ * QEMU Block driver for CLOOP images
*
* Copyright (c) 2004 Johannes E. Schindelin
*
@@ -149,6 +149,8 @@ static void cloop_close(BlockDriverState *bs)
{
BDRVCloopState *s = bs->opaque;
close(s->fd);
+ if(s->n_blocks>0)
+ free(s->offsets);
free(s->compressed_block);
free(s->uncompressed_block);
inflateEnd(&s->zstream);