diff options
author | Zac Medico <zmedico@gentoo.org> | 2009-08-18 21:10:43 +0000 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2009-08-18 21:10:43 +0000 |
commit | b712814fe5dcccf0d8d5bced54ac563206f3c566 (patch) | |
tree | 81aa3f6aba799059a9b8cde957e5350918ccad70 | |
parent | 4a68aff462b82f5d3048b77fa559155e9343077d (diff) | |
download | portage-b712814fe5dcccf0d8d5bced54ac563206f3c566.tar.gz portage-b712814fe5dcccf0d8d5bced54ac563206f3c566.tar.bz2 portage-b712814fe5dcccf0d8d5bced54ac563206f3c566.zip |
Use errors='backslashreplace' instead of 'replace' for the default
_unicode_encode() argument ('replace' substitutes '?', which is not
as useful).
svn path=/main/trunk/; revision=14092
-rw-r--r-- | pym/portage/__init__.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/pym/portage/__init__.py b/pym/portage/__init__.py index c8100b396..480e00f81 100644 --- a/pym/portage/__init__.py +++ b/pym/portage/__init__.py @@ -131,7 +131,8 @@ _content_encoding = _encodings['content'] _fs_encoding = _encodings['fs'] _merge_encoding = _encodings['merge'] -def _unicode_encode(s, encoding=_encodings['content'], errors='replace'): +def _unicode_encode(s, encoding=_encodings['content'], + errors='backslashreplace'): if isinstance(s, unicode): s = s.encode(encoding, errors) return s |