Paolo Bonzini <pbonz...@redhat.com> writes: > Casting to/from void* must be explicit in C++. g_new0 takes care of that. > > Signed-off-by: Paolo Bonzini <pbonz...@redhat.com> > --- > include/qemu/timer.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/include/qemu/timer.h b/include/qemu/timer.h > index 88ef114689..ee071e07d1 100644 > --- a/include/qemu/timer.h > +++ b/include/qemu/timer.h > @@ -520,7 +520,7 @@ static inline QEMUTimer > *timer_new_full(QEMUTimerListGroup *timer_list_group, > int scale, int attributes, > QEMUTimerCB *cb, void *opaque) > { > - QEMUTimer *ts = g_malloc0(sizeof(QEMUTimer)); > + QEMUTimer *ts = g_new0(QEMUTimer, 1); > timer_init_full(ts, timer_list_group, type, scale, attributes, cb, > opaque); > return ts; > }
Looks like a rerun of commit b45c03f585's Coccinelle script is due. I'll take care of it.