From: Zac Medico Date: Thu, 18 Oct 2012 03:32:20 +0000 (-0700) Subject: bintree/portree: fix getslot for EAPI 5 sub-slot X-Git-Tag: v2.2.0_alpha141~7 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=5608e26193249acf4d072f7658f88ea7e7222ae4;p=portage.git bintree/portree: fix getslot for EAPI 5 sub-slot --- diff --git a/pym/portage/dbapi/bintree.py b/pym/portage/dbapi/bintree.py index cbcfa728f..f90a4936f 100644 --- a/pym/portage/dbapi/bintree.py +++ b/pym/portage/dbapi/bintree.py @@ -1484,9 +1484,7 @@ class binarytree(object): "Get a slot for a catpkg; assume it exists." myslot = "" try: - myslot = self.dbapi.aux_get(mycatpkg,["SLOT"])[0] - except SystemExit as e: - raise - except Exception as e: + myslot = self.dbapi._pkg_str(mycatpkg, None).slot + except KeyError: pass return myslot diff --git a/pym/portage/dbapi/porttree.py b/pym/portage/dbapi/porttree.py index a5945be59..115fc7f29 100644 --- a/pym/portage/dbapi/porttree.py +++ b/pym/portage/dbapi/porttree.py @@ -1063,10 +1063,8 @@ class portagetree(object): "Get a slot for a catpkg; assume it exists." myslot = "" try: - myslot = self.dbapi.aux_get(mycatpkg, ["SLOT"])[0] - except SystemExit: - raise - except Exception: + myslot = self.dbapi._pkg_str(mycatpkg, None).slot + except KeyError: pass return myslot