[asterisk-dev] [asterisk-commits] tilghman: trunk r221920 - /trunk/main/logger.c

Kevin P. Fleming kpfleming at digium.com
Fri Oct 2 10:34:58 CDT 2009

Tilghman Lesher wrote:

> Valgrind did not report that it was not initialized.  However, the log message
> list had 4GB of memory allocated to it, and it was still growing.  I looked
> through the code and what it appeared like to me was that the thread was
> started at boot and immediately exited, thus the memory wasn't likely to ever
> be freed.

Bizarre. I'd suggest adding a printf() in logger_init() to show the
value of that variable without the explicit initialization, just to
confirm that it was already zero... we have dozens of other module-scope
variables throughout Asterisk already that we rely on being
automatically initialized to zero.

Kevin P. Fleming
Digium, Inc. | Director of Software Technologies
445 Jan Davis Drive NW - Huntsville, AL 35806 - USA
skype: kpfleming | jabber: kpfleming at digium.com
Check us out at www.digium.com & www.asterisk.org

More information about the asterisk-dev mailing list