diff --git a/pyfpdb/Database.py b/pyfpdb/Database.py old mode 100755 new mode 100644 diff --git a/pyfpdb/fpdb.py b/pyfpdb/fpdb.py index 7da93e87..47d3bc55 100755 --- a/pyfpdb/fpdb.py +++ b/pyfpdb/fpdb.py @@ -595,7 +595,7 @@ class fpdb: self.warning_box("MySQL Server reports: Access denied. Are your permissions set correctly?") exit() except Exceptions.FpdbMySQLNoDatabase: - msg = "MySQL client reports: 2002 error. Unable to connect - Please check that the MySQL service has been started" + msg = "MySQL client reports: 2002 or 2003 error. Unable to connect - Please check that the MySQL service has been started" self.warning_box(msg) exit diff --git a/pyfpdb/fpdb_db.py b/pyfpdb/fpdb_db.py index 8a0ec54e..405a142c 100644 --- a/pyfpdb/fpdb_db.py +++ b/pyfpdb/fpdb_db.py @@ -106,7 +106,7 @@ class fpdb_db: except MySQLdb.Error, ex: if ex.args[0] == 1045: raise FpdbMySQLAccessDenied(ex.args[0], ex.args[1]) - elif ex.args[0] == 2002: + elif ex.args[0] == 2002 or ex.args[0] == 2003: # 2002 is no unix socket, 2003 is no tcp socket raise FpdbMySQLNoDatabase(ex.args[0], ex.args[1]) else: print "*** WARNING UNKNOWN MYSQL ERROR", ex