enigma-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Enigma-devel] leak hunting - report


From: Petr Machata
Subject: Re: [Enigma-devel] leak hunting - report
Date: Sun, 22 Jun 2003 14:50:04 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.3; MultiZilla v1.4.0.2) Gecko/20030312

Ralf Westram wrote:
Hello Petr,


I wasn't able to remove all leaks. Valgrind claims that there are
currenly some 250 KB leaked, and this leak occurs even if all you do is
enter the game and exit immediately.

My valgrind (1.0.4) reports 230k of these 250k as 'still reachable'. A
quick look showed that most of these are caused by static data. I
think we should not worry about it.


I did some additional valgrinding:

- some leaks were caused by missing virtual destructors. I think they
occur because some objects were allocated with 'new DerivedClass'
but free'd using 'delete BaseClass'.
- many leaks are from an lua-realloc function (but I don't understand
how they happen).

Yes, I noticed it. There is a number of them. I looked carefully to lua.cc and tolua-generated sources, found one leak in LUA script, but really didn't find anything to eliminate those malloc and realloc leaks. Is it possible that LUA engine itself leaks? Valgrind also states a few leaks in SDL and X libraries, so anything is possible, I think.


Ralf


Petr Machata






reply via email to

[Prev in Thread] Current Thread [Next in Thread]