Changeset 1142
- Timestamp:
- 07/27/07 21:57:34 (6 years ago)
- Files:
-
- 1 modified
-
trunk/umitCore/I18N.py (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/umitCore/I18N.py
r1141 r1142 26 26 LC_ALL = locale.setlocale(locale.LC_ALL, '') 27 27 LANG, ENC = locale.getdefaultlocale() 28 ERRORS = " replace"28 ERRORS = "strict" 29 29 30 30 # If not correct locale could be retrieved, set en_US.utf8 as default … … 56 56 """ 57 57 log.debug(">>> Converting '%s' from '%s' to unicode" % (string, ENC)) 58 string = string.decode(ENC, ERRORS)58 string = unicode(string, ENC, ERRORS) 59 59 log.debug(">>> Converted to: '%s'" % string) 60 60
