diff options
author | Peter Crosthwaite | 2014-08-15 10:15:44 +0200 |
---|---|---|
committer | Michael Tokarev | 2014-08-15 16:54:55 +0200 |
commit | 8945c7f75419a8191f3e99b341f1a485b48af766 (patch) | |
tree | 71de00ee36b0b38c5d1397c10f5e78244421b05e /hw | |
parent | ppc: convert g_new(qemu_irq usages to g_new0 (diff) | |
download | qemu-8945c7f75419a8191f3e99b341f1a485b48af766.tar.gz qemu-8945c7f75419a8191f3e99b341f1a485b48af766.tar.xz qemu-8945c7f75419a8191f3e99b341f1a485b48af766.zip |
intc: i8259: Convert Array allocation to g_new0
To be more array friendly and to indicate the IRQs are initially
disconnected.
Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
Diffstat (limited to 'hw')
-rw-r--r-- | hw/intc/i8259.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/intc/i8259.c b/hw/intc/i8259.c index d0b0c52b97..a563b82c4e 100644 --- a/hw/intc/i8259.c +++ b/hw/intc/i8259.c @@ -472,7 +472,7 @@ qemu_irq *i8259_init(ISABus *bus, qemu_irq parent_irq) ISADevice *isadev; int i; - irq_set = g_malloc(ISA_NUM_IRQS * sizeof(qemu_irq)); + irq_set = g_new0(qemu_irq, ISA_NUM_IRQS); isadev = i8259_init_chip(TYPE_I8259, bus, true); dev = DEVICE(isadev); |