From 78b924c8521b7a594938a0f54b821e114eb15245 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Mon, 10 Feb 2020 11:53:21 +0100 Subject: switch test suite on UDS using patch from https://github.com/glpi-project/glpi/pull/6921 fix FTBFS with mariadb 10.4 #1799419 --- 6921.patch | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 6921.patch (limited to '6921.patch') diff --git a/6921.patch b/6921.patch new file mode 100644 index 0000000..80ff8eb --- /dev/null +++ b/6921.patch @@ -0,0 +1,26 @@ +From 205a35302eb50cb6ef88f66187e6d9bbb52a501a Mon Sep 17 00:00:00 2001 +From: Remi Collet +Date: Mon, 10 Feb 2020 11:37:39 +0100 +Subject: [PATCH] Fix #6919 allow installation on UDS + +--- + inc/console/database/installcommand.class.php | 6 +++++- + 1 file changed, 5 insertions(+), 1 deletion(-) + +diff --git a/inc/console/database/installcommand.class.php b/inc/console/database/installcommand.class.php +index 6f0b45961c..5d9387bf24 100644 +--- a/inc/console/database/installcommand.class.php ++++ b/inc/console/database/installcommand.class.php +@@ -235,7 +235,11 @@ protected function execute(InputInterface $input, OutputInterface $output) { + } + + $mysqli = new \mysqli(); +- @$mysqli->connect($db_host, $db_user, $db_pass, null, $db_port); ++ if (intval($db_port) > 0) { // Network port ++ @$mysqli->connect($db_host, $db_user, $db_pass, null, $db_port); ++ } else { // Unix Domain Socket ++ @$mysqli->connect($db_host, $db_user, $db_pass, null, 0, $db_port); ++ } + + if (0 !== $mysqli->connect_errno) { + $message = sprintf( -- cgit