From e8b48654914cf2f6fcc968c526810b95dded3c16 Mon Sep 17 00:00:00 2001 From: Chris Hofstaedtler Date: Fri, 10 Aug 2018 14:46:05 +0200 Subject: [PATCH] Workaround MariaDB pretending to be MySQL (cherry picked from commit 7906a5d37203a8c3c4fb130d482442c3ba151e3b) --- modules/gmysqlbackend/smysql.cc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/modules/gmysqlbackend/smysql.cc b/modules/gmysqlbackend/smysql.cc index 8a2a5092a..12f2a175b 100644 --- a/modules/gmysqlbackend/smysql.cc +++ b/modules/gmysqlbackend/smysql.cc @@ -32,6 +32,12 @@ #include "pdns/namespaces.hh" #include "pdns/lock.hh" +#if MYSQL_VERSION_ID >= 80000 && !defined(MARIADB_BASE_VERSION) +// Need to keep this for compatibility with MySQL < 8.0.0, which used typedef char my_bool; +// MariaDB up to 10.4 also always define it. +typedef bool my_bool; +#endif + bool SMySQL::s_dolog; pthread_mutex_t SMySQL::s_myinitlock = PTHREAD_MUTEX_INITIALIZER; -- 2.40.0