From 2137b4cca9af2ca22b527ef9f3835c532511453d Mon Sep 17 00:00:00 2001 From: ths Date: Wed, 6 Aug 2008 08:37:17 +0000 Subject: Add qemu_realloc(), by Gerd Hoffmann. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4986 c046a42c-6fe2-441c-8c8c-71466251a162 --- block-dmg.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'block-dmg.c') diff --git a/block-dmg.c b/block-dmg.c index 62117c97ae..8c9d0da2ca 100644 --- a/block-dmg.c +++ b/block-dmg.c @@ -125,11 +125,11 @@ dmg_close: goto dmg_close; chunk_count = (count-204)/40; new_size = sizeof(uint64_t) * (s->n_chunks + chunk_count); - s->types = realloc(s->types, new_size/2); - s->offsets = realloc(s->offsets, new_size); - s->lengths = realloc(s->lengths, new_size); - s->sectors = realloc(s->sectors, new_size); - s->sectorcounts = realloc(s->sectorcounts, new_size); + s->types = qemu_realloc(s->types, new_size/2); + s->offsets = qemu_realloc(s->offsets, new_size); + s->lengths = qemu_realloc(s->lengths, new_size); + s->sectors = qemu_realloc(s->sectors, new_size); + s->sectorcounts = qemu_realloc(s->sectorcounts, new_size); for(i=s->n_chunks;in_chunks+chunk_count;i++) { s->types[i] = read_uint32(s->fd); -- cgit v1.2.1