diff --git a/bureau/class/m_mysql.php b/bureau/class/m_mysql.php index e155d402..e1dfad23 100644 --- a/bureau/class/m_mysql.php +++ b/bureau/class/m_mysql.php @@ -145,7 +145,7 @@ class m_mysql { $lo=addslashes($db->f("login")); $pa=addslashes($db->f("pass")); } - if ($db->query("CREATE DATABASE $dbname;")) { + if ($db->query("CREATE DATABASE `$dbname`;")) { // Ok, database does not exist, quota is ok and dbname is compliant. Let's proceed $db->query("INSERT INTO db (uid,login,pass,db,bck_mode) VALUES ('$cuid','$lo','$pa','$dbname',0);"); // give everything but GRANT on db.* diff --git a/debian/changelog b/debian/changelog index f139e1fb..3ea45aeb 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,6 +1,7 @@ alternc (0.9.10) stable; urgency=low * bugfixes: + * fix a "already exist" error when creating a database containing an hyphen (-) * #1163: fix sqlbackup script call routine to retain backwards compatibility * fix usage of ISO8859-15 charset (that may NOT be defined in locales...)