提交 a70a0ca0 authored 作者: Anthony Minessale's avatar Anthony Minessale

declinatio mortuus obfirmo

上级 a5cbf1d9
...@@ -6467,7 +6467,8 @@ void sofia_glue_actually_execute_sql_trans(sofia_profile_t *profile, char *sql, ...@@ -6467,7 +6467,8 @@ void sofia_glue_actually_execute_sql_trans(sofia_profile_t *profile, char *sql,
if (!(dbh = sofia_glue_get_db_handle(profile))) { if (!(dbh = sofia_glue_get_db_handle(profile))) {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Error Opening DB\n"); switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Error Opening DB\n");
return;
goto end;
} }
switch_cache_db_persistant_execute_trans_full(dbh, sql, 1, switch_cache_db_persistant_execute_trans_full(dbh, sql, 1,
...@@ -6479,6 +6480,8 @@ void sofia_glue_actually_execute_sql_trans(sofia_profile_t *profile, char *sql, ...@@ -6479,6 +6480,8 @@ void sofia_glue_actually_execute_sql_trans(sofia_profile_t *profile, char *sql,
switch_cache_db_release_db_handle(&dbh); switch_cache_db_release_db_handle(&dbh);
end:
if (mutex) { if (mutex) {
switch_mutex_unlock(mutex); switch_mutex_unlock(mutex);
} }
...@@ -6495,6 +6498,11 @@ void sofia_glue_actually_execute_sql(sofia_profile_t *profile, char *sql, switch ...@@ -6495,6 +6498,11 @@ void sofia_glue_actually_execute_sql(sofia_profile_t *profile, char *sql, switch
if (!(dbh = sofia_glue_get_db_handle(profile))) { if (!(dbh = sofia_glue_get_db_handle(profile))) {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Error Opening DB\n"); switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Error Opening DB\n");
if (mutex) {
switch_mutex_unlock(mutex);
}
return; return;
} }
...@@ -6525,6 +6533,11 @@ switch_bool_t sofia_glue_execute_sql_callback(sofia_profile_t *profile, ...@@ -6525,6 +6533,11 @@ switch_bool_t sofia_glue_execute_sql_callback(sofia_profile_t *profile,
if (!(dbh = sofia_glue_get_db_handle(profile))) { if (!(dbh = sofia_glue_get_db_handle(profile))) {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Error Opening DB\n"); switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Error Opening DB\n");
if (mutex) {
switch_mutex_unlock(mutex);
}
return ret; return ret;
} }
...@@ -6559,6 +6572,11 @@ char *sofia_glue_execute_sql2str(sofia_profile_t *profile, switch_mutex_t *mutex ...@@ -6559,6 +6572,11 @@ char *sofia_glue_execute_sql2str(sofia_profile_t *profile, switch_mutex_t *mutex
if (!(dbh = sofia_glue_get_db_handle(profile))) { if (!(dbh = sofia_glue_get_db_handle(profile))) {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Error Opening DB\n"); switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Error Opening DB\n");
if (mutex) {
switch_mutex_unlock(mutex);
}
return NULL; return NULL;
} }
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论