From ae79ceb3a426c7da1a39e968d9b86e1d212b9dbc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Tue, 2 Aug 2016 08:53:06 +0200 Subject: [PATCH] Do not error on unset server port MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fixes #12339 Signed-off-by: Michal Čihař --- ChangeLog | 1 + libraries/DatabaseInterface.php | 3 +++ 2 files changed, 4 insertions(+) diff --git a/ChangeLog b/ChangeLog index 9db5b722d2..fe94b98788 100644 --- a/ChangeLog +++ b/ChangeLog @@ -16,6 +16,7 @@ phpMyAdmin - ChangeLog - issue #12425 Duplicate message variable names in messages.inc.php - issue #12399 Adding index to table shows wrong top navigation - issue #12424 Fixed password change on MariaDB without auth plugin +- issue #12339 Do not error on unset server port 4.6.3 (2016-06-23) - issue #12249 Fixed cookie path on Windows diff --git a/libraries/DatabaseInterface.php b/libraries/DatabaseInterface.php index b394b01b43..e4c3ed5026 100644 --- a/libraries/DatabaseInterface.php +++ b/libraries/DatabaseInterface.php @@ -2713,6 +2713,9 @@ class DatabaseInterface $server = &$GLOBALS['cfg']['Server']; } + if (empty($server['port'])) { + return 0; + } return intval($server['port']); }