From 7267c0947d7e8ae5dff7bafd932c3bc285f43e5c Mon Sep 17 00:00:00 2001 From: Anthony Liguori Date: Sat, 20 Aug 2011 22:09:37 -0500 Subject: Use glib memory allocation and free functions qemu_malloc/qemu_free no longer exist after this commit. Signed-off-by: Anthony Liguori --- hw/rc4030.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'hw/rc4030.c') diff --git a/hw/rc4030.c b/hw/rc4030.c index 6563336dd0..a2a20996a2 100644 --- a/hw/rc4030.c +++ b/hw/rc4030.c @@ -789,8 +789,8 @@ static rc4030_dma *rc4030_allocate_dmas(void *opaque, int n) struct rc4030DMAState *p; int i; - s = (rc4030_dma *)qemu_mallocz(sizeof(rc4030_dma) * n); - p = (struct rc4030DMAState *)qemu_mallocz(sizeof(struct rc4030DMAState) * n); + s = (rc4030_dma *)g_malloc0(sizeof(rc4030_dma) * n); + p = (struct rc4030DMAState *)g_malloc0(sizeof(struct rc4030DMAState) * n); for (i = 0; i < n; i++) { p->opaque = opaque; p->n = i; @@ -806,7 +806,7 @@ void *rc4030_init(qemu_irq timer, qemu_irq jazz_bus, rc4030State *s; int s_chipset, s_jazzio; - s = qemu_mallocz(sizeof(rc4030State)); + s = g_malloc0(sizeof(rc4030State)); *irqs = qemu_allocate_irqs(rc4030_irq_jazz_request, s, 16); *dmas = rc4030_allocate_dmas(s, 4); -- cgit 1.4.1