changeset ac4eca09dd3d in /home/hg/repos/gajim
details:http://hg.gajim.org/gajim?cmd=changeset;node=ac4eca09dd3d description: fix some encoding problems when looking for plugin config with non-ascii chars in path. Fixes #7015
diffstat:
src/gajim.py | 7 ++++--- 1 files changed, 4 insertions(+), 3 deletions(-)
diffs (27 lines):
diff -r a9ebbf95ae2e -r ac4eca09dd3d src/gajim.py --- a/src/gajim.py Sun Oct 23 13:48:00 2011 +0200 +++ b/src/gajim.py Sun Oct 23 18:55:14 2011 +0200 @@ -142,10 +142,11 @@ config_path_ = a return profile_, config_path_
+import locale profile, config_path = parseOpts() +config_path = unicode(config_path, locale.getpreferredencoding()) del parseOpts
-import locale profile = unicode(profile, locale.getpreferredencoding())
import common.configpaths @@ -155,8 +156,8 @@ del profile
if os.name == 'nt': - plugins_locale_dir = str(os.path.join(common.configpaths.gajimpaths[ - 'PLUGINS_USER'], 'locale')) + plugins_locale_dir = os.path.join(common.configpaths.gajimpaths[ + 'PLUGINS_USER'], 'locale').encode(locale.getpreferredencoding()) libintl.bindtextdomain('gajim_plugins', plugins_locale_dir) libintl.bind_textdomain_codeset('gajim_plugins', 'UTF-8')