From ecf15cf982a08782446afedc82071057b0c2592d Mon Sep 17 00:00:00 2001 From: ralf Date: Thu, 21 Apr 2022 19:52:19 +0200 Subject: [PATCH] fix "Invalid character set was provided" error in newer MariaDB when trying to enter setup --- setup/inc/class.setup.inc.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/setup/inc/class.setup.inc.php b/setup/inc/class.setup.inc.php index c5109407e9..ed05fc3ecf 100644 --- a/setup/inc/class.setup.inc.php +++ b/setup/inc/class.setup.inc.php @@ -145,7 +145,8 @@ class setup } if (!$api_version || !$this->alessthanb($api_version,'1.0.1.019')) { - $this->db->Link_ID->SetCharSet($this->system_charset); + $this->db->Link_ID->SetCharSet($this->system_charset === 'utf-8' && + $this->db->Type === 'mysql' ? 'utf8' : $this->system_charset); } } } @@ -1293,4 +1294,4 @@ class setup //echo "

setup::set_table_names: $name = '{$this->$name}'

\n"; } } -} +} \ No newline at end of file