From 4eaf906dae802829b689d81ccb7257afb557de5a Mon Sep 17 00:00:00 2001 From: Fabrizio Gennari Date: Sat, 23 Mar 2024 10:27:12 +0100 Subject: [PATCH] Do not ignore the socket passed with the -S option, even when no port is passed --- changelog.md | 1 + mycli/AUTHORS | 1 + mycli/main.py | 1 + 3 files changed, 3 insertions(+) diff --git a/changelog.md b/changelog.md index 367e62c8..c004761e 100644 --- a/changelog.md +++ b/changelog.md @@ -4,6 +4,7 @@ Upcoming Bug Fixes: ---------- * Don't install tests. +* Do not ignore the socket passed with the -S option, even when no port is passed 1.27.0 (2023/08/11) =================== diff --git a/mycli/AUTHORS b/mycli/AUTHORS index 133b8fc1..5e75b4cc 100644 --- a/mycli/AUTHORS +++ b/mycli/AUTHORS @@ -35,6 +35,7 @@ Contributors: * Daniel Black * Daniel West * Daniël van Eeden + * Fabrizio Gennari * François Pietka * Frederic Aoustin * Georgy Frolov diff --git a/mycli/main.py b/mycli/main.py index 02a09cf9..be2354a3 100755 --- a/mycli/main.py +++ b/mycli/main.py @@ -427,6 +427,7 @@ def connect(self, database='', user='', passwd='', host='', port='', port = 3306 if not host or host == 'localhost': socket = ( + socket or cnf['socket'] or cnf['default_socket'] or guess_socket_location()