diff options
Diffstat (limited to 'pym/portage/__init__.py')
-rw-r--r-- | pym/portage/__init__.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/pym/portage/__init__.py b/pym/portage/__init__.py index 169c19783..6d7b1019e 100644 --- a/pym/portage/__init__.py +++ b/pym/portage/__init__.py @@ -181,6 +181,8 @@ if sys.hexversion >= 0x3000000: if isinstance(s, bytes): s = str(s, encoding=encoding, errors=errors) return s + + _native_string = _unicode_decode else: def _unicode_encode(s, encoding=_encodings['content'], errors='backslashreplace'): if isinstance(s, unicode): @@ -192,6 +194,8 @@ else: s = unicode(s, encoding=encoding, errors=errors) return s + _native_string = _unicode_encode + class _unicode_func_wrapper(object): """ Wraps a function, converts arguments from unicode to bytes, |