From c0b3c923a46afc12837698a78a11b17a7fc384d8 Mon Sep 17 00:00:00 2001 From: Tilghman Lesher Date: Mon, 9 Nov 2009 07:37:52 +0000 Subject: Fix various problems detected with Valgrind. * chan_console accessed pvts after deallocation. * cdr_mysql stored a pointer that was freed by realloc() * The module loader did not check usecount on shutdown, which led to chan_iax2 reading a timer that was already unloaded. * The event subsystem sometimes creates an event with no IEs. Due to a corner condition, the code would read beyond the memory boundary. * res_pktccops did not correctly check whether its monitor thread was started. (closes issue #16062) Reported by: alexanderheinz Patches: 20091109__issue16062.diff.txt uploaded by tilghman (license 14) Tested by: tilghman git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@228798 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- channels/chan_console.c | 1 + 1 file changed, 1 insertion(+) (limited to 'channels/chan_console.c') diff --git a/channels/chan_console.c b/channels/chan_console.c index 9141c3d1d..df23c3dd1 100644 --- a/channels/chan_console.c +++ b/channels/chan_console.c @@ -1500,6 +1500,7 @@ return_error_pa_init: return_error: if (pvts) ao2_ref(pvts, -1); + pvts = NULL; pvt_destructor(&globals); return AST_MODULE_LOAD_DECLINE; -- cgit v1.2.3