egencache: ensure correct porttrees
authorZac Medico <zmedico@gentoo.org>
Sat, 29 Oct 2011 19:38:51 +0000 (12:38 -0700)
committerZac Medico <zmedico@gentoo.org>
Sat, 29 Oct 2011 19:38:51 +0000 (12:38 -0700)
The GenCache class assumes that portdb.porttrees[0] is the desired
tree, so assert that it is true. The behavior should have already been
correct, since PORTDIR_OVERLAY was already set to an empty string when
necessary.

bin/egencache

index 01eadf053cff2430db61ab966462202b00642b1b..22ce8ec33c23783788809bb07406ae07f9d1b4fb 100755 (executable)
@@ -864,6 +864,8 @@ def egencache_main(args):
 
                # Limit ebuilds to the specified repo.
                portdb.porttrees = [repo_path]
+       else:
+               portdb.porttrees = [portdb.porttree_root]
 
        ret = [os.EX_OK]