Hi Dave,

"GObject type registration machinery is, under normal circumstances, only ever 
used tocreate structures that will exist during the entire program lifetime."

Does that mean that if I just use straight old malloc() instead of g_slice(), 
most of the errors would go away? I gather that's essentially what using 
G_SLICE=always-malloc would do.


I can't try this out until late tonight, unfortunately.


________________________________
 From: David Nečas <y...@physics.muni.cz>
To: David Buchan <pdbuc...@yahoo.com> 
Cc: gtk-app-devel-list list <gtk-app-devel-list@gnome.org> 
Sent: Tuesday, November 5, 2013 2:51 PM
Subject: Re: Valgrind is grinding my gears
 

On Tue, Nov 05, 2013 at 09:47:13AM -0800, David Buchan wrote:

> But when I invoke Valgrind at runtime, I get a lot of errors which I
> can't make any sense of.
> 
> I have grabbed a small sample of them here:
> 
> http://pdbuchan.com/valgrind.txt
> 
> I don't like ignoring errors and warnings, but I don't know what to do
> with these.
> 
> Has anybody else come across these types of Valgrind notifications?

Yes, everyone.  You must understand that all the GObject type
registration machinery is, under normal circumstances, only ever used to
create structures that will exist during the entire program lifetime.
So although things such as class reference leaks can exists, eveything
inside g_type_class_ref() should be ignorable – and you can clearly see
from the log that these allocations happen once, not a thousand times.
The same for g_thread_init(), gtk_init(), etc.  Create a suppression
file or google one...

Regards,

Yeti
_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Reply via email to