git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@32709
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
# http://www.alanwood.net/demos/charsetdiffs.html for differences
# between the common latin/roman encodings.
import locale
-default = locale.getdefaultlocale()[1]
+try:
+ default = locale.getdefaultlocale()[1]
+except ValueError:
+ default = "iso8859-1"
if default:
wx.SetDefaultPyEncoding(default)
del default
# http://www.alanwood.net/demos/charsetdiffs.html for differences
# between the common latin/roman encodings.
import locale
-default = locale.getdefaultlocale()[1]
+try:
+ default = locale.getdefaultlocale()[1]
+except ValueError:
+ default = "iso8859-1"
if default:
wx.SetDefaultPyEncoding(default)
del default