mirror of
https://github.com/inspircd/inspircd.git
synced 2025-03-09 18:49:03 -04:00
Fix an incompatibility between MySQL and MariaDB.
This commit is contained in:
parent
3af79a556e
commit
1ac8bbe178
@ -342,8 +342,10 @@ class SQLConnection : public SQL::Provider
|
||||
mysql_options(connection, MYSQL_OPT_CONNECT_TIMEOUT, &timeout);
|
||||
|
||||
// Enable SSL if requested.
|
||||
#if defined LIBMYSQL_VERSION_ID && LIBMYSQL_VERSION_ID > 80000
|
||||
unsigned int ssl = config->getBool("ssl") ? SSL_MODE_REQUIRED : SSL_MODE_PREFERRED;
|
||||
mysql_options(connection, MYSQL_OPT_SSL_MODE, &ssl);
|
||||
#endif
|
||||
|
||||
// Attempt to connect to the database.
|
||||
const std::string host = config->getString("host");
|
||||
|
Loading…
x
Reference in New Issue
Block a user