summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--pym/portage/dbapi/vartree.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/pym/portage/dbapi/vartree.py b/pym/portage/dbapi/vartree.py
index 7bc2c686e..64fafbb57 100644
--- a/pym/portage/dbapi/vartree.py
+++ b/pym/portage/dbapi/vartree.py
@@ -1701,7 +1701,8 @@ class dblink(object):
# do we have a origin repository name for the current package
repopath = os.sep.join(self.settings["O"].split(os.sep)[:-2])
- if mydbapi != None:
+ # bindbapi has no getRepositories() method
+ if mydbapi and hasattr(mydbapi, "getRepositories"):
for reponame in mydbapi.getRepositories():
if mydbapi.getRepositoryPath(reponame) == repopath:
fd = open(os.path.join(self.dbtmpdir, "repository"), "w")