diff options
author | 2013-10-09 23:35:30 -0400 | |
---|---|---|
committer | 2013-10-28 22:29:10 -0400 | |
commit | a5962e6adaef7201233e235401d50fb96142d7d6 (patch) | |
tree | 585b8351b0672599df54c17b9b272aaff6bb8d43 /WebappConfig/dotconfig.py | |
parent | WebappConfig/content.py: Encodes md5 content in utf-8 when writing. (diff) | |
download | webapp-config-a5962e6adaef7201233e235401d50fb96142d7d6.tar.gz webapp-config-a5962e6adaef7201233e235401d50fb96142d7d6.tar.bz2 webapp-config-a5962e6adaef7201233e235401d50fb96142d7d6.zip |
WebappConfig/dotconfig.py: Encodes .webapp info in utf-8 when writing.
Diffstat (limited to 'WebappConfig/dotconfig.py')
-rw-r--r-- | WebappConfig/dotconfig.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/WebappConfig/dotconfig.py b/WebappConfig/dotconfig.py index ce2845c..cab0392 100644 --- a/WebappConfig/dotconfig.py +++ b/WebappConfig/dotconfig.py @@ -248,7 +248,6 @@ class DotConfig: '# automatically created by Gentoo\'s webapp-config', '# do NOT edit this file by hand', '',] - for i in self.__tokens: info.append(i + '="' + self.__data[i] + '"') @@ -259,7 +258,7 @@ class DotConfig: os.O_WRONLY | os.O_CREAT, self.__perm(0o600)) - os.write(fd, '\n'.join(info)) + os.write(fd, ('\n'.join(info)).encode('utf-8')) os.close(fd) except Exception as e: |