diff options
author | Markus Armbruster <armbru@redhat.com> | 2013-01-15 15:29:10 +0100 |
---|---|---|
committer | Stefan Hajnoczi <stefanha@redhat.com> | 2013-01-15 17:28:55 +0100 |
commit | 7191bf311ea9722cdcc3b2229788eff69d896bd0 (patch) | |
tree | 8f2f912d31b034c8a27bab9aff10e984dd4fcfc9 /block/mirror.c | |
parent | 7479acdbce2ecf6cbd0b7d72b81608c8fc51b1ae (diff) | |
download | qemu-7191bf311ea9722cdcc3b2229788eff69d896bd0.tar.gz qemu-7191bf311ea9722cdcc3b2229788eff69d896bd0.tar.bz2 qemu-7191bf311ea9722cdcc3b2229788eff69d896bd0.zip |
block: Fix how mirror_run() frees its buffer
It allocates with qemu_blockalign(), therefore it must free with
qemu_vfree(), not g_free().
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'block/mirror.c')
-rw-r--r-- | block/mirror.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/block/mirror.c b/block/mirror.c index 8aeacbf12c..6180aa30e5 100644 --- a/block/mirror.c +++ b/block/mirror.c @@ -225,7 +225,7 @@ static void coroutine_fn mirror_run(void *opaque) } immediate_exit: - g_free(s->buf); + qemu_vfree(s->buf); bdrv_set_dirty_tracking(bs, false); bdrv_iostatus_disable(s->target); if (s->should_complete && ret == 0) { |