Merge branch 'master' of git://git.assembla.com/fpdb-eric
This commit is contained in:
commit
b5e64fd747
0
pyfpdb/Database.py
Executable file → Normal file
0
pyfpdb/Database.py
Executable file → Normal file
|
@ -595,7 +595,7 @@ class fpdb:
|
||||||
self.warning_box("MySQL Server reports: Access denied. Are your permissions set correctly?")
|
self.warning_box("MySQL Server reports: Access denied. Are your permissions set correctly?")
|
||||||
exit()
|
exit()
|
||||||
except Exceptions.FpdbMySQLNoDatabase:
|
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)
|
self.warning_box(msg)
|
||||||
exit
|
exit
|
||||||
|
|
||||||
|
|
|
@ -106,7 +106,7 @@ class fpdb_db:
|
||||||
except MySQLdb.Error, ex:
|
except MySQLdb.Error, ex:
|
||||||
if ex.args[0] == 1045:
|
if ex.args[0] == 1045:
|
||||||
raise FpdbMySQLAccessDenied(ex.args[0], ex.args[1])
|
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])
|
raise FpdbMySQLNoDatabase(ex.args[0], ex.args[1])
|
||||||
else:
|
else:
|
||||||
print "*** WARNING UNKNOWN MYSQL ERROR", ex
|
print "*** WARNING UNKNOWN MYSQL ERROR", ex
|
||||||
|
|
Loading…
Reference in New Issue
Block a user