summaryrefslogtreecommitdiff
path: root/giscanner/xmlwriter.py
diff options
context:
space:
mode:
authorJohan Dahlin <johan@gnome.org>2010-12-02 14:10:33 -0200
committerJohan Dahlin <johan@gnome.org>2010-12-02 14:10:33 -0200
commitb6405089448ea588989faf1b4bff3aa96cd5c291 (patch)
treeb236aebc6f9593c9b121f7d2ba209c8a9dd0e527 /giscanner/xmlwriter.py
parentaa8b7d2d0f586976ea7399d95e1ccce3000b4734 (diff)
downloadgobject-introspection-b6405089448ea588989faf1b4bff3aa96cd5c291.tar.gz
Add proper unicode support to the source scanner
The assumption is that the only allowed source encoding is utf-8. Always strings as unicode and fix up the transformer and xml writer to properly output utf-8.
Diffstat (limited to 'giscanner/xmlwriter.py')
-rwxr-xr-xgiscanner/xmlwriter.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/giscanner/xmlwriter.py b/giscanner/xmlwriter.py
index a418cc40..84c24c0f 100755
--- a/giscanner/xmlwriter.py
+++ b/giscanner/xmlwriter.py
@@ -120,7 +120,7 @@ class XMLWriter(object):
if indent:
self._data.write('%s%s%s' % (
self._indent_char * self._indent,
- line,
+ line.encode('utf-8'),
self._newline_char))
else:
self._data.write('%s%s' % (line, self._newline_char))