An open-source ODBC driver manager and SDK that facilitates the development of database-independent applications on linux, freebsd, unix and MacOS X platforms.
We call SQLDriverConnect() which get lock using ENTER_HDBC(). Then the SQLSetConnectOptionW() is called which also get lock using ENTER_HDBC(). The second ENTER_HDBC() cause the deadlock.
The test:
CheckBeforeConnect(SQL_ATTR_LOGIN_TIMEOUT, value, value); This function set the connect attribute before connection using SQLSetConnectAttr() and then calls SQLDriverConnect().
We call SQLDriverConnect() which get lock using ENTER_HDBC(). Then the SQLSetConnectOptionW() is called which also get lock using ENTER_HDBC(). The second ENTER_HDBC() cause the deadlock.
The test: CheckBeforeConnect(SQL_ATTR_LOGIN_TIMEOUT, value, value); This function set the connect attribute before connection using SQLSetConnectAttr() and then calls SQLDriverConnect().
Stack trace: