On Tue, Sep 27, 2005, Olaf Seibert wrote about "[ctwm] Re: ctwm memory leaks?": > There is one possibility that I can think of: that in your version it > does behave like my theory. It seems that my version is XFree86 4.5.0 > (or derived from it). What's your X version?
I just thought of a better reason why the free/XFree mismatched might have discovered a *false* leak. My leak detector works by changing all calls to malloc/free/etc. to calls to __wrap_malloc etc. during the linking stage (see the "--wrap" option of ld). These wrappers follow which memory gets allocated, and which gets freed later. Now, it is likely that what happened is that calls to XFree() do not change during linking and remain calls to XFree(), and then, during *dynamic linking* (at run time), the real free() gets called, and our allocator doesn't know the memory it allocated got freed. So, I'm sorry about this false leak report, but I guess that it is a wise idea to clean up the XFree/free mismatch anyway, even if it's not a real leak. P.S. This issue brings me to thinking that I need to try some sort of LD_PRELOAD trick to enforce my malloc/free/etc wrappers also on shared libraries used by ctwm. I'll try this approach later and see if it helps. -- Nadav Har'El | Tuesday, Sep 27 2005, 24 Elul 5765 [EMAIL PROTECTED] |----------------------------------------- Phone +972-523-790466, ICQ 13349191 |Spelling mistakes left in for people who http://nadav.harel.org.il |feel the need to correct others.
