]> git.joonet.de Git - adminer.git/commitdiff
MySQL: Fix connecting with port (fix #1057, regression from 5.1.1)
authorJakub Vrana <jakub@vrana.cz>
Thu, 24 Apr 2025 20:31:03 +0000 (22:31 +0200)
committerJakub Vrana <jakub@vrana.cz>
Thu, 24 Apr 2025 20:31:03 +0000 (22:31 +0200)
CHANGELOG.md
adminer/drivers/mysql.inc.php

index 8e4ffacdfa73f2064162cda468fb4bde19c75c35..a884b5c4bd84ea23bc51e554506b691f3e1e8285 100644 (file)
@@ -4,6 +4,7 @@
 - Fix type error in Create function (bug #1053)
 - MySQL: Avoid warning on selecting tables with fulltext indexes (bug #1036)
 - MySQL, PostgreSQL: Support index algorithms (bug #1030)
+- MySQL: Fix connecting with port (bug #1057, regression from 5.1.1)
 - PostgreSQL, CockroachDB: Creating partitioned tables (bug #1031)
 - PostgreSQL: Move partitioned tables from table list to parent table
 - PostgreSQL: Support partial indices (bug #1048)
index cd82724fd8c5769506bf4286820a51cb5456eb7b..6b5dfe68a4482e5edc0a973b9fc31f27b3c62fa7 100644 (file)
@@ -29,7 +29,7 @@ if (!defined('Adminer\DRIVER')) {
                                        ($server . $username . $password != "" ? $password : ini_get("mysqli.default_pw")),
                                        null,
                                        (is_numeric($port) ? intval($port) : ini_get("mysqli.default_port")),
-                                       (is_numeric($port) ? $port : null),
+                                       (is_numeric($port) ? null : $port),
                                        ($ssl ? ($ssl['verify'] !== false ? 2048 : 64) : 0) // 2048 - MYSQLI_CLIENT_SSL, 64 - MYSQLI_CLIENT_SSL_DONT_VERIFY_SERVER_CERT (not available before PHP 5.6.16)
                                );
                                $this->options(MYSQLI_OPT_LOCAL_INFILE, false);