aboutsummaryrefslogtreecommitdiffstats
path: root/cel
diff options
context:
space:
mode:
authormarkm <markm@f38db490-d61c-443f-a65b-d21fe96a405b>2011-05-19 18:12:49 +0000
committermarkm <markm@f38db490-d61c-443f-a65b-d21fe96a405b>2011-05-19 18:12:49 +0000
commit771fec8633f2b834c551214ce430e564be150a51 (patch)
treed3e1dbbeaec2977b2a8446eff68d00f1d6455b1f /cel
parentd9fd1e85da69e972fc463bfdb57715504f5f3708 (diff)
Merged revisions 319812 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8 ........ r319812 | markm | 2011-05-19 13:59:01 -0400 (Thu, 19 May 2011) | 9 lines In cel_odbc, an uninitialized RWLIST is attempted to be locked. Added INIT and DESTROY for the RWLIST odbc_tables (closes issue #19331) Reported by: kobaz Patches: odbc_cel.patch uploaded by kobaz (license 834) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@319813 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'cel')
-rw-r--r--cel/cel_odbc.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/cel/cel_odbc.c b/cel/cel_odbc.c
index cf970690b..d298f1ba2 100644
--- a/cel/cel_odbc.c
+++ b/cel/cel_odbc.c
@@ -751,11 +751,15 @@ static int unload_module(void)
free_config();
AST_RWLIST_UNLOCK(&odbc_tables);
+ AST_RWLIST_HEAD_DESTROY(&odbc_tables);
+
return 0;
}
static int load_module(void)
{
+ AST_RWLIST_HEAD_INIT(&odbc_tables);
+
if (AST_RWLIST_WRLOCK(&odbc_tables)) {
ast_log(LOG_ERROR, "Unable to lock column list. Load failed.\n");
return 0;