From: Zac Medico Date: Fri, 22 Jun 2007 00:18:41 +0000 (-0000) Subject: if requested argv cannot be matched to anything, exit with non-zero status (trunk... X-Git-Tag: v2.1.3~186 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=3c3eadfb8ecc2ce5b3eb2c1fa93404193453f49e;p=portage.git if requested argv cannot be matched to anything, exit with non-zero status (trunk r5791) svn path=/main/branches/2.1.2/; revision=6924 --- diff --git a/bin/portageq b/bin/portageq index 1a59af8bc..6147e5627 100755 --- a/bin/portageq +++ b/bin/portageq @@ -133,7 +133,12 @@ def best_visible(argv): sys.exit(2) try: mylist=portage.db[argv[0]]["porttree"].dbapi.match(argv[1]) - print portage.best(mylist) + visible=portage.best(mylist) + if visible: + print visible + sys.exit(0) + else: + sys.exit(1) except KeyError: sys.exit(1) best_visible.uses_root = True