Fix error under Cygwin Python:
File "/usr/lib/python3.4/encodings/cp1251.py", line 19, in encode
return codecs.charmap_encode(input,self.errors,encoding_table)[0]
UnicodeEncodeError: 'charmap' codec can't encode characters in position 0-1: character maps to <undefined>
--- a/py/gadict_c5.py Sun May 15 09:26:03 2016 +0300
+++ b/py/gadict_c5.py Sun May 15 23:45:44 2016 +0300
@@ -3,6 +3,7 @@
import io
import sys
+import codecs
import gadict
@@ -48,7 +49,7 @@
if FONAME is None:
FOUT = sys.stdout
else:
- FOUT = open(FONAME, "w")
+ FOUT = codecs.open(FONAME, "w", "utf-8")
if PRELUDE.name is not None:
FOUT.write("Dictionary name: ")