diff options
author | file <file@f38db490-d61c-443f-a65b-d21fe96a405b> | 2006-10-23 00:25:28 +0000 |
---|---|---|
committer | file <file@f38db490-d61c-443f-a65b-d21fe96a405b> | 2006-10-23 00:25:28 +0000 |
commit | 4e364351a129e4434e262d929e83469a013e6cb6 (patch) | |
tree | 2501b6fda8dcdec8a298aa08614afb99fa05f520 /cdr | |
parent | 3222639fcd8e3512ac6ccbf4f0ed8b7e316194be (diff) |
Don't leak memory mmmk?
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.2@45927 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'cdr')
-rw-r--r-- | cdr/cdr_odbc.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/cdr/cdr_odbc.c b/cdr/cdr_odbc.c index 474ce4968..7a50bf21d 100644 --- a/cdr/cdr_odbc.c +++ b/cdr/cdr_odbc.c @@ -341,7 +341,6 @@ static int odbc_load_module(void) goto out; } - ast_config_destroy(cfg); if (option_verbose > 2) { ast_verbose( VERBOSE_PREFIX_3 "cdr_odbc: dsn is %s\n",dsn); if (username) @@ -366,6 +365,8 @@ static int odbc_load_module(void) ast_log(LOG_ERROR, "cdr_odbc: Unable to register ODBC CDR handling\n"); } out: + if (cfg) + ast_config_destroy(cfg); ast_mutex_unlock(&odbc_lock); return res; } |