Ignore broken locale configuration.

This commit is contained in:
Bastian Kleineidam 2012-06-20 21:44:57 +02:00
parent 3dd35c57a8
commit 22a4d48d68

View file

@ -136,8 +136,8 @@ def get_locale ():
@rtype (string, string)"""
try:
loc, encoding = locale.getdefaultlocale()
except ValueError, msg:
print >>sys.stderr, "Error getting default locale:", msg
except ValueError:
# locale configuration is broken - ignore that
loc, encoding = None, None
if loc is None:
loc = "C"