[asterisk-dev] Query on Memory Management Guidelines

Russell Bryant russell at digium.com
Mon Jul 23 07:13:11 CDT 2007


Grey Man wrote:
> One test I did on my patch was to turn on the MALLOC_DEBUG flag and use "show memory summary app_dial.c" before and after a call. In doing so I was seeing an increase per call of approx. 64 bytes. As best as I could tell (and I could be very wrong so please excuse me if so) the problem was not down to my modifications but to line 1593 in app_dial.c:

Another thing you can do is compare the output of "show memory
allocations app_dial.c" before and after the call.  If there is a leak
in there, you should see an additional entry that was not there before.
 It will point you to the line number where the allocation was made.

It may not have been your fault.  :)

-- 
Russell Bryant
Software Engineer
Digium, Inc.



More information about the asterisk-dev mailing list