From a93ae7a2529035c9f801dcc350c92e6045cd0c34 Mon Sep 17 00:00:00 2001 From: lanjelot Date: Fri, 7 Jan 2022 14:49:42 +1000 Subject: [PATCH] Fix #172 --- patator.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/patator.py b/patator.py index 06bc120..f37de96 100755 --- a/patator.py +++ b/patator.py @@ -3535,7 +3535,10 @@ class MySQL_login: try: with Timing() as timing: - fp = _mysql.connect(host=host, port=int(port), user=user, passwd=password, connect_timeout=int(timeout)) + if PY3: + fp = _mysql.connect(host=host, port=int(port), user=user, password=password, connect_timeout=int(timeout)) + else: + fp = _mysql.connect(host=host, port=int(port), user=user, passwd=password, connect_timeout=int(timeout)) resp = '0', fp.get_server_info()