Use _get_masking_status() for the --autounmaks KEYWORDS check.
authorZac Medico <zmedico@gentoo.org>
Fri, 6 Aug 2010 12:42:07 +0000 (05:42 -0700)
committerZac Medico <zmedico@gentoo.org>
Fri, 6 Aug 2010 12:42:07 +0000 (05:42 -0700)
pym/_emerge/depgraph.py

index 4addbd449225e2d34df84d3bc4b499c7c1bf971b..4dd3c3f1c08ce11f7c99d8ce976bf6fdec81c8f7 100644 (file)
@@ -2538,8 +2538,10 @@ class depgraph(object):
 
                if not allow_missing_keywords:
                        return False
-               mreasons = get_masking_status(pkg, pkgsettings, root_config)
-               if len(mreasons) == 1 and mreasons[0].startswith("~") and mreasons[0].endswith("keyword"):
+               mreasons = _get_masking_status(pkg, pkgsettings, root_config)
+               if len(mreasons) == 1 and \
+                       mreasons[0].category == 'KEYWORDS' and \
+                       mreasons[0].message.startswith("~"):
                        return True
                else:
                        return False