[asterisk-dev] memory leaks

Beau Hargis beauh at bluefrogmobile.com
Thu Jan 26 22:36:46 MST 2006


On Thu, 2006-01-26 at 22:48 -0600, Tilghman Lesher wrote:
> On Thursday 26 January 2006 19:31, Beau Hargis wrote:
> > I am seeing what look like memory leaks. I am using the 1.2.x
> > branch updated as of a couple of hours ago. I saw really, really
> > bad memory leaks with res_perl loaded in and being used. I
> > eliminated the res_perl stuff and use AGI instead, but the memory
> > leaks still seemed to continue. I put it into valgrind and it kept
> > reporting:
> >
> > ==3441== Warning: invalid file descriptor 1017 in syscall close()
> > ==3441== Warning: invalid file descriptor 1018 in syscall close()
> > ==3441== Warning: invalid file descriptor 1019 in syscall close()
> > ==3441== Warning: invalid file descriptor 1020 in syscall close()
> > ==3441== Warning: invalid file descriptor 1021 in syscall close()
> > ==3441== Warning: invalid file descriptor 1022 in syscall close()
> > ==3441== Warning: invalid file descriptor 1023 in syscall close()
> > ==3445== Warning: invalid file descriptor 1014 in syscall close()
> > ==3445== Warning: invalid file descriptor 1015 in syscall close()
> > ==3445== Warning: invalid file descriptor 1016 in syscall close()
> >
> > over and over several times during every call after each instance
> > of AGI being called. The summary at the end did say quite a bit
> > about memory leaks being present.
> 
> Those messages are completely unrelated to any memory leaks.  Those
> messages relate to a forked process needing to close all open file
> descriptors before execing the AGI program.
> 

Yes, I realize that, but valgrind did spit out a lot of messages
regarding memory leaks. I was not sure if those file descriptor errors
were file descriptors leaking and then some time down the line causing
asterisk to just quit.

I will run valgrind and post up the results it give me. I have it
compiled with -O0 -g3 and it was giving me similar results regardless of
the optimization options.



More information about the asterisk-dev mailing list