summaryrefslogtreecommitdiff
path: root/src/common.py
diff options
context:
space:
mode:
authorlouiz@4325f9fc-e183-4c21-96ce-0ab188b42d13 <louiz@4325f9fc-e183-4c21-96ce-0ab188b42d13>2010-08-14 08:58:31 +0000
committerlouiz@4325f9fc-e183-4c21-96ce-0ab188b42d13 <louiz@4325f9fc-e183-4c21-96ce-0ab188b42d13>2010-08-14 08:58:31 +0000
commit20b1f687642ee91a423204ee13e14161df3946dd (patch)
tree02e2deb8d39c7202e8e01d8ac17f20c49d33bbb4 /src/common.py
parent79ce5c23324880b7cc7df3dea73dffee45131566 (diff)
downloadpoezio-20b1f687642ee91a423204ee13e14161df3946dd.tar.gz
poezio-20b1f687642ee91a423204ee13e14161df3946dd.tar.bz2
poezio-20b1f687642ee91a423204ee13e14161df3946dd.tar.xz
poezio-20b1f687642ee91a423204ee13e14161df3946dd.zip
Fix a little bug on completion due to the separating line
Diffstat (limited to 'src/common.py')
-rw-r--r--src/common.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/common.py b/src/common.py
index bd79b788..93eca601 100644
--- a/src/common.py
+++ b/src/common.py
@@ -62,7 +62,13 @@ def debug(string):
a CLI software
"""
fdes = open("debug", 'a')
- fdes.write(string)
+ try:
+ fdes.write(string)
+ except:
+ try:
+ fdes.write(string.encode('utf-8'))
+ except:
+ fdes.write(string.encode('utf-8'))
fdes.close()
def get_base64_from_file(path):