Fixed mysql/mariadb compatibility issue
This commit is contained in:
@@ -19,13 +19,13 @@ int setTimeout(struct stored_conn_t *sconn, unsigned int timeout)
|
||||
{
|
||||
sconn->timeout = timeout;
|
||||
|
||||
if (mysql_optionsv(SQCONN(sconn), MYSQL_OPT_CONNECT_TIMEOUT, (void *)&timeout) != 0) {
|
||||
if (mysql_options(SQCONN(sconn), MYSQL_OPT_CONNECT_TIMEOUT, (void *)&timeout) != 0) {
|
||||
return -1;
|
||||
}
|
||||
if (mysql_optionsv(SQCONN(sconn), MYSQL_OPT_READ_TIMEOUT, (void *)&timeout) != 0) {
|
||||
if (mysql_options(SQCONN(sconn), MYSQL_OPT_READ_TIMEOUT, (void *)&timeout) != 0) {
|
||||
return -1;
|
||||
}
|
||||
if (mysql_optionsv(SQCONN(sconn), MYSQL_OPT_WRITE_TIMEOUT, (void *)&timeout) != 0) {
|
||||
if (mysql_options(SQCONN(sconn), MYSQL_OPT_WRITE_TIMEOUT, (void *)&timeout) != 0) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user