fix off-by-one bug in ConfigSubList
authorFelix Domke <tmbinc@elitedvb.net>
Sun, 8 Oct 2006 21:07:33 +0000 (21:07 +0000)
committerFelix Domke <tmbinc@elitedvb.net>
Sun, 8 Oct 2006 21:07:33 +0000 (21:07 +0000)
lib/python/Components/config.py

index 3b64763..0718615 100644 (file)
@@ -631,8 +631,8 @@ class ConfigSubList(list, object):
        saved_value = property(getSavedValue, setSavedValue)
        
        def append(self, item):
        saved_value = property(getSavedValue, setSavedValue)
        
        def append(self, item):
-               list.append(self, item)
                i = str(len(self))
                i = str(len(self))
+               list.append(self, item)
                if i in self.stored_values:
                        item.saved_value = self.stored_values[i]
                        item.load()
                if i in self.stored_values:
                        item.saved_value = self.stored_values[i]
                        item.load()