From fc0b5e7903f27685152934eef4a5889a13fb8a75 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Sun, 4 Nov 2007 09:31:30 +0000 Subject: [PATCH] In portdbapi.cp_list(), validate the ebuild name to ensure that it matches the name of the package. (trunk r8421) svn path=/main/branches/2.1.2/; revision=8422 --- pym/portage.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pym/portage.py b/pym/portage.py index 53e3089b0..4c118cb4b 100644 --- a/pym/portage.py +++ b/pym/portage.py @@ -6777,6 +6777,10 @@ class portdbapi(dbapi): writemsg("\nInvalid ebuild name: %s\n" % \ os.path.join(oroot, mycp, x), noiselevel=-1) continue + if ps[0] != mysplit[1]: + writemsg("\nInvalid ebuild name: %s\n" % \ + os.path.join(oroot, mycp, x), noiselevel=-1) + continue d[mysplit[0]+"/"+pf] = None if invalid_category and d: writemsg(("\n!!! '%s' has a category that is not listed in " + \ -- 2.26.2