Re: Memory leaks and destruction of widgets
- From: Havoc Pennington <hp redhat com>
- To: "Ian King" <king eiffel com>
- Cc: "GTKLIST" <gtk-list gnome org>
- Subject: Re: Memory leaks and destruction of widgets
- Date: 02 Aug 2001 16:04:40 -0400
"Ian King" <king eiffel com> writes:
>
> Okay, I do have a global tooltips object, I do have this convenience feature
> that connects the tooltip text, but if I do not explicitly reset the tooltip
> text with a NULL pointer then the memory just keeps going up and up... and
> up. I thought this was the solution to my problems, our application is
> creating a lot of widgets and can leak up to half a megabyte per change of
> state, tracking down this problem is a bit of a nightmare.
Perhaps there's a bug, or perhaps your widgets never get the destroy
signal properly emitted - it's hard to say. If you file a
bugzilla.gnome.org report with test case, someone will look into it
eventually, or you could see what you can figure out.
Look at the source code for gtk_tooltips_set_tip(), it clearly frees
the tooltip data when the widget is destroyed.
> Apart from the obvious I meant, with tooltips being one. As I am not
> directly deallocating any memory (or unreferencing any object), just setting
> the tooltip to a NULL pointer, I was wondering if there were any other
> scenarios such as this.
I'm not sure this scenario exists - if it did, I would consider it
very broken. I don't know of other such things.
Havoc
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]