From: Tilghman Lesher Date: Sat, 12 Jan 2008 00:17:26 +0000 (+0000) Subject: Merged revisions 98467 via svnmerge from X-Git-Tag: 1.6.0-beta1~3^2~69 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fa4f7d3727b2647d9563273a1ada5935972d0ae4;p=thirdparty%2Fasterisk.git Merged revisions 98467 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r98467 | tilghman | 2008-01-11 18:05:08 -0600 (Fri, 11 Jan 2008) | 4 lines Add a connection timeout attribute, as that was what was intended with the login timeout, but ODBC divides it up into 2 different timeouts. (Closes issue #11745) ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@98487 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/res/res_odbc.c b/res/res_odbc.c index 391a20371e..c35a4319f4 100644 --- a/res/res_odbc.c +++ b/res/res_odbc.c @@ -550,6 +550,7 @@ static odbc_status odbc_obj_connect(struct odbc_obj *obj) return ODBC_FAIL; } SQLSetConnectAttr(obj->con, SQL_LOGIN_TIMEOUT, (SQLPOINTER *) 10, 0); + SQLSetConnectAttr(obj->con, SQL_ATTR_CONNECTION_TIMEOUT, (SQLPOINTER *) 10, 0); #ifdef NEEDTRACE SQLSetConnectAttr(obj->con, SQL_ATTR_TRACE, &enable, SQL_IS_INTEGER); SQLSetConnectAttr(obj->con, SQL_ATTR_TRACEFILE, tracefile, strlen(tracefile));