encode utf8 result

This commit is contained in:
Elan Ruusamäe 2012-09-18 22:43:59 +02:00
parent 75f25748cb
commit 21cb1f23a6

View file

@ -27,6 +27,6 @@ class DokuWiki:
if not self.callcache.has_key(key):
cmd = ['./doku.php', method ] + args
res = subprocess.Popen(cmd, stdin = None, stdout = subprocess.PIPE, stderr = sys.stderr, close_fds = True).communicate()
print "%s->%s" % (cmd, res)
self.callcache[key] = res[0]
self.callcache[key] = unicode(res[0].decode('utf-8'))
print "%s->%s" % (cmd, self.callcache[key])
return self.callcache[key]