]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Ensure that logmsgs are freed properly
authorKinsey Moore <kmoore@digium.com>
Thu, 7 Mar 2013 15:08:26 +0000 (15:08 +0000)
committerKinsey Moore <kmoore@digium.com>
Thu, 7 Mar 2013 15:08:26 +0000 (15:08 +0000)
Messages sent while the logger thread is shutting down will now have
their associated callid freed properly.

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/11@382574 65c4cc65-6c06-0410-ace0-fbb531ad65f3

main/logger.c

index 8cad8e4e69264ccfe45b1bc334d79261a5125ce1..c753e965c0459f04a2ccae3bd0d07816c2b1d06e 100644 (file)
@@ -1519,7 +1519,7 @@ static void __attribute__((format(printf, 6, 0))) ast_log_full(int level, const
                AST_LIST_LOCK(&logmsgs);
                if (close_logger_thread) {
                        /* Logger is either closing or closed.  We cannot log this message. */
-                       ast_free(logmsg);
+                       logmsg_free(logmsg);
                } else {
                        AST_LIST_INSERT_TAIL(&logmsgs, logmsg, list);
                        ast_cond_signal(&logcond);