summaryrefslogtreecommitdiffstats
path: root/pym
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2007-12-21 01:28:17 +0000
committerZac Medico <zmedico@gentoo.org>2007-12-21 01:28:17 +0000
commit29e5d9911713307e14601e43960b51967928e4c8 (patch)
treea1f14949adb094b3bc6cea8b86e82bc6c50811fc /pym
parent48fd5974353350d8fdf9de2f2a1273f09ec48091 (diff)
downloadportage-29e5d9911713307e14601e43960b51967928e4c8.tar.gz
portage-29e5d9911713307e14601e43960b51967928e4c8.tar.bz2
portage-29e5d9911713307e14601e43960b51967928e4c8.zip
Use regex category validation in binarytree.populate().
(trunk r9011:9013) svn path=/main/branches/2.1.2/; revision=9014
Diffstat (limited to 'pym')
-rw-r--r--pym/portage.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/pym/portage.py b/pym/portage.py
index 08accebd4..007991615 100644
--- a/pym/portage.py
+++ b/pym/portage.py
@@ -7685,7 +7685,7 @@ class binarytree(object):
if mycpv in pkg_paths:
# All is first, so it's preferred.
continue
- if not mycat:
+ if not self.dbapi._category_re.match(mycat):
writemsg(("!!! Binary package has an " + \
"unrecognized category: '%s'\n") % full_path,
noiselevel=-1)
@@ -7725,7 +7725,7 @@ class binarytree(object):
continue
mycat=self.remotepkgs[mypkg]["CATEGORY"].strip()
fullpkg=mycat+"/"+mypkg[:-5]
- if not mycat:
+ if not self.dbapi._category_re.match(mycat):
writemsg(("!!! Remote binary package has an " + \
"unrecognized category: '%s'\n") % fullpkg,
noiselevel=-1)