Release list lock before returning on error.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@268933 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
parent
8872926df7
commit
523e4e50bf
|
@ -686,12 +686,14 @@ static struct sqlite_cache_tables *find_table(const char *tablename)
|
|||
ast_log(LOG_WARNING, "SQLite error %d: %s\n", err, errstr);
|
||||
ast_free(errstr);
|
||||
free_table(tblptr);
|
||||
AST_RWLIST_UNLOCK(&sqlite_tables);
|
||||
return NULL;
|
||||
}
|
||||
ast_mutex_unlock(&mutex);
|
||||
|
||||
if (AST_LIST_EMPTY(&(tblptr->columns))) {
|
||||
free_table(tblptr);
|
||||
AST_RWLIST_UNLOCK(&sqlite_tables);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue