From: Zac Medico Date: Mon, 13 Nov 2006 00:50:54 +0000 (-0000) Subject: For bug #154921, prevent an IndexError when a + is in USE. X-Git-Tag: v2.1.2~479 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=4ab2e29f2881596bee4dbf065aa3ce0e92d870fd;p=portage.git For bug #154921, prevent an IndexError when a + is in USE. svn path=/main/trunk/; revision=5021 --- diff --git a/pym/portage.py b/pym/portage.py index 2f146a019..13646b2fb 100644 --- a/pym/portage.py +++ b/pym/portage.py @@ -1691,6 +1691,8 @@ class config: writemsg(red("USE flags should not start with a '+': %s\n" % x), noiselevel=-1) x=x[1:] + if not x: + continue if (x[0]=="-"): if (x[1:] in myflags): @@ -1758,6 +1760,8 @@ class config: writemsg(colorize("BAD", "USE flags should not start " + \ "with a '+': %s\n" % x), noiselevel=-1) x = x[1:] + if not x: + continue if x[0] == "-": try: