Re: [gtk-list] Re: how can I trust glib when it has somanymemleaks?
- From: Scott !!! <ttarrant suntlc etnoteam it>
- To: gtk-list redhat com
- Subject: Re: [gtk-list] Re: how can I trust glib when it has somanymemleaks?
- Date: Thu, 18 Mar 1999 10:21:03 +0100 (MET)
On Thu, 18 Mar 1999, Ionutz Borcoman wrote:
> Please detail one thing here: memory is alocated by my program using
> glib. You say UNIX will free all the memory. Why isn't it freeing the
> memory allocated by glib also ? What is the use of ccmalloc if memory is
> freed by system when my program finishes ? Just to ensure that my
> program doesn't grow too much while running ?
When you link ccmalloc in your program, it will give you a list of
unallocated memory BEFORE termination of the program. When the program dies,
the OS reclaims all of its memory. That happens AFTER ccmalloc has shown you
its statistics. I thought it was obvious.
You're reiterating the same concepts over and over again... the Glib developers
are very talented guys, and their code is exceptionally clean and well
organized. I seem to remember reading that someone was using purify at one
point or another on Glib/Gtk+ to track memory leaks.
The only solution I can think about this problem is a function,
glib_shutdown(), which should be called before exiting which will deallocate
KNOWN memory chunks. In this way ccmalloc will only display real leaks...
Anyone interested in taking this up ?
Tristan
--
Tristan Tarrant ttarrant@etnoteam.it
Linux - la scelta di una GNUova generazione
Linux - the choice of a GNU generation
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]