]> git.ipfire.org Git - thirdparty/qemu.git/blobdiff - hw/timer/slavio_timer.c
Use g_new() & friends where that makes obvious sense
[thirdparty/qemu.git] / hw / timer / slavio_timer.c
index 03e33fc592665360a72e87e1ac642157276a605f..90fdce4c442b312876e435afea2a1c846509e569 100644 (file)
@@ -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;