Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTomeu Vizoso <tomeu@sugarlabs.org>2009-08-30 14:30:46 (GMT)
committer Tomeu Vizoso <tomeu@sugarlabs.org>2009-08-30 14:30:46 (GMT)
commitcee382b3ad89d7009f4e5c8fa6ec9c54e8a8ac1d (patch)
treecd334a507bd77de7617793a7d6423d7e755a708e
parent59fe05fc41ba630a280b4c2b70bf4cb0027044a0 (diff)
Deal with unicode nick names (erikos) #889
-rw-r--r--src/buddy.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/buddy.py b/src/buddy.py
index 2b83ee4..e85a925 100644
--- a/src/buddy.py
+++ b/src/buddy.py
@@ -974,9 +974,12 @@ class ShellOwner(GenericOwner):
key_hash = profile.privkey_hash
key = profile.pubkey
- nick = client.get_string("/desktop/sugar/user/nick")
color = client.get_string("/desktop/sugar/user/color")
tags = client.get_string("/desktop/sugar/user/tags")
+ nick = client.get_string("/desktop/sugar/user/nick")
+
+ if not isinstance(nick, unicode):
+ nick = unicode(nick, 'utf-8')
icon_file = os.path.join(env.get_profile_path(), "buddy-icon.jpg")
f = open(icon_file, "r")