diff options
Diffstat (limited to 'cdr/cdr_odbc.c')
-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 f916a8d85..79ea1453a 100644 --- a/cdr/cdr_odbc.c +++ b/cdr/cdr_odbc.c @@ -346,7 +346,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) @@ -371,6 +370,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; } |