Fixed MariaDB compilation
Follow up to da73084 Thanks to @SapitoSucio and @Singe-Horizontal
This commit is contained in:
parent
da73084df5
commit
7313495185
@ -121,11 +121,13 @@ int Sql_Connect(Sql* self, const char* user, const char* passwd, const char* hos
|
|||||||
|
|
||||||
StringBuf_Clear(&self->buf);
|
StringBuf_Clear(&self->buf);
|
||||||
|
|
||||||
|
#if !defined(MARIADB_BASE_VERSION) && !defined(MARIADB_VERSION_ID) && MYSQL_VERSION_ID >= 50710
|
||||||
unsigned int md = SSL_MODE_DISABLED;
|
unsigned int md = SSL_MODE_DISABLED;
|
||||||
|
|
||||||
if( mysql_options( &self->handle, MYSQL_OPT_SSL_MODE, &md ) ){
|
if( mysql_options( &self->handle, MYSQL_OPT_SSL_MODE, &md ) ){
|
||||||
ShowSQL( "Your MySQL version does not understand \"MYSQL_OPT_SSL_MODE\" yet. Please consider upgrading - especially if you encounter SSL related error messages from your MySQL server.\n" );
|
ShowSQL( "Your MySQL version does not understand \"MYSQL_OPT_SSL_MODE\" yet. Please consider upgrading - especially if you encounter SSL related error messages from your MySQL server.\n" );
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
if( !mysql_real_connect(&self->handle, host, user, passwd, db, (unsigned int)port, NULL/*unix_socket*/, 0/*clientflag*/) )
|
if( !mysql_real_connect(&self->handle, host, user, passwd, db, (unsigned int)port, NULL/*unix_socket*/, 0/*clientflag*/) )
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user