aboutsummaryrefslogtreecommitdiffstats
path: root/cdr
diff options
context:
space:
mode:
authortilghman <tilghman@f38db490-d61c-443f-a65b-d21fe96a405b>2010-12-16 00:30:04 +0000
committertilghman <tilghman@f38db490-d61c-443f-a65b-d21fe96a405b>2010-12-16 00:30:04 +0000
commit36b00ceb5e27c965bbdf18cb827e34ec480cdeeb (patch)
tree04c074555f4c00910532d74551c7f36dd6ed165f /cdr
parentd2c11b54624bdde12c456c15ef74b0485f251d71 (diff)
Merged revisions 298393 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.6.2 ................ r298393 | tilghman | 2010-12-15 18:29:10 -0600 (Wed, 15 Dec 2010) | 15 lines Merged revisions 298392 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r298392 | tilghman | 2010-12-15 18:28:04 -0600 (Wed, 15 Dec 2010) | 8 lines Unregister before shutting down the connection, to avoid a race. (closes issue #18481) Reported by: pabelanger Patches: 20101215__issue18481.diff.txt uploaded by tilghman (license 14) Tested by: pabelanger ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.8@298394 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'cdr')
-rw-r--r--cdr/cdr_sqlite.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/cdr/cdr_sqlite.c b/cdr/cdr_sqlite.c
index a46902c9c..e21d33659 100644
--- a/cdr/cdr_sqlite.c
+++ b/cdr/cdr_sqlite.c
@@ -188,9 +188,10 @@ static int sqlite_log(struct ast_cdr *cdr)
static int unload_module(void)
{
- if (db)
- sqlite_close(db);
ast_cdr_unregister(name);
+ if (db) {
+ sqlite_close(db);
+ }
return 0;
}