diff options
-rw-r--r-- | pym/portage/dbapi/bintree.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/pym/portage/dbapi/bintree.py b/pym/portage/dbapi/bintree.py index 41da32d39..2b4dd1834 100644 --- a/pym/portage/dbapi/bintree.py +++ b/pym/portage/dbapi/bintree.py @@ -21,6 +21,7 @@ from portage.localization import _ from portage import dep_expand, listdir, _check_distfile, _movefile +import codecs import os, errno, stat import re from itertools import chain, izip @@ -847,7 +848,8 @@ class binarytree(object): created_symlink = True pkgindex = self._new_pkgindex() try: - f = open(self._pkgindex_file) + f = codecs.open(self._pkgindex_file, + encoding='utf_8', errors='replace') except EnvironmentError: pass else: |