mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-04-13 15:50:59 +00:00
set maximum query run time to 30 seconds at least on drivers that support SQL_ATTR_QUERY_TIMEOUT
This commit is contained in:
parent
2c595a6ce0
commit
5bb525e1ea
@ -165,6 +165,8 @@ static int db_is_up(switch_odbc_handle_t *handle)
|
||||
goto error;
|
||||
}
|
||||
|
||||
SQLSetStmtAttr(stmt, SQL_ATTR_QUERY_TIMEOUT, (SQLPOINTER)30, 0);
|
||||
|
||||
if (SQLPrepare(stmt, sql, SQL_NTS) != SQL_SUCCESS) {
|
||||
code = __LINE__;
|
||||
goto error;
|
||||
|
Loading…
x
Reference in New Issue
Block a user