LocationsManager: empty profiles_complex on error
authorZac Medico <zmedico@gentoo.org>
Wed, 25 Apr 2012 16:37:48 +0000 (09:37 -0700)
committerZac Medico <zmedico@gentoo.org>
Wed, 25 Apr 2012 16:41:08 +0000 (09:41 -0700)
This prevents an IndexError in code which assumes that profiles and
profiles_complex are the same length.

pym/portage/package/ebuild/_config/LocationsManager.py

index 8ad41f74776f6869660f393326b7eecedbfba9ac..9c73612fed9e46b2fd1ae13cc90dd9cbb3820182 100644 (file)
@@ -90,6 +90,7 @@ class LocationsManager(object):
                                        self.profile_path, noiselevel=-1)
                                writemsg("!!! ParseError: %s\n" % str(e), noiselevel=-1)
                                self.profiles = []
+                               self.profiles_complex = []
 
                if self._user_config and self.profiles:
                        custom_prof = os.path.join(