Hello Comments inside: > It should not have memory leaks, at least from what I see > when it is running. It should not - but it have !!! > The best check would be if you print > removedList size each time and see whether it grows to infinity. This patch do it in more precise way - it show separate calls with memory leak (not only common total number of calls in this list). You can add counter into it in very easy way if you will need it. With current patch it show problem per each separate call. > PS: I don't know what your patch shows - it is normal to have > used calls in removedList - their reference count drops each > time some assciated object (like signaling socket) is deleted > and finally should reach 0. Yes I know it very well. IsUsed() in CallRec must delay deletion until SendReleaseComplete or signaling sockets use CallRec. In other words this mean that sample after 10 min after call drop moment - nothing must use CallRec and it must be deleted. It is not happend ! Deleted calls stay for hours in this list !!! I was done simple tests: 1) download official stable 2.0x code in tgz 2) patch it with my demo patch to show possible memory leask 3) compile gnugk with latest openh323lib / pwlib 4) run it with -tttttt 5) make single normal call in GW-GW mode over this binary and drop it 6) wait for 1 hour to be sure that all delayed objects will be deleted 7) look into -tttttt log 8) log show that after CDR generated list of removed calls got 1 call with IsUsed() flag and it was to attempted to delete each second from CheckCalls() but failed (because it marked with used flag). Igor > ----- Original Message ----- > From: <ii7@xxxxx> > Sent: Tuesday, November 23, 2004 11:32 PM >> Latest GnuGK 2.0x have stable memory leak at fixed place. >> >> After call completed gnugk generate CDR and move >> current call (CallRec) into RemovedList. >> >> CheckCalls() function called each second and check list >> of calls inside RemovedList. It must do final delete >> of CallRec objects in this list that not marked as used. >> >> Problem that calls are marked as "used" forever and >> as result calls stay undeleted inside RemovedList. >> This fact is source point of memory leak described >> in this mail. >> >> Patch that show this problem attached. >> >> Can anybody comment how to solve this problem ? >> >> Thanks in advance >> >> Igor Ivanov ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://productguide.itmanagersjournal.com/ _______________________________________________________ List: Openh323gk-users@xxxxxxxxxxxxxxxxxxxxx Archive: http://sourceforge.net/mailarchive/forum.php?forum_id=8549 Homepage: http://www.gnugk.org/