summaryrefslogtreecommitdiffstats
path: root/6921.patch
diff options
context:
space:
mode:
authorRemi Collet <remi@remirepo.net>2020-02-10 11:53:21 +0100
committerRemi Collet <remi@remirepo.net>2020-02-10 11:53:21 +0100
commit78b924c8521b7a594938a0f54b821e114eb15245 (patch)
tree42226334a112a07768c4c0a5451ce6e07e672546 /6921.patch
parent6b6d9808b4c724b43cd4942a0e54677448363070 (diff)
switch test suite on UDS using patch from
https://github.com/glpi-project/glpi/pull/6921 fix FTBFS with mariadb 10.4 #1799419
Diffstat (limited to '6921.patch')
-rw-r--r--6921.patch26
1 files changed, 26 insertions, 0 deletions
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 <remi@remirepo.net>
+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(