summaryrefslogtreecommitdiff
path: root/hw/timer/slavio_timer.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/timer/slavio_timer.c')
-rw-r--r--hw/timer/slavio_timer.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/timer/slavio_timer.c b/hw/timer/slavio_timer.c
index 03e33fc592..90fdce4c44 100644
--- a/hw/timer/slavio_timer.c
+++ b/hw/timer/slavio_timer.c
@@ -400,7 +400,7 @@ static void slavio_timer_init(Object *obj)
uint64_t size;
char timer_name[20];
- tc = g_malloc0(sizeof(TimerContext));
+ tc = g_new0(TimerContext, 1);
tc->s = s;
tc->timer_index = i;