From: Felix Domke Date: Mon, 2 Mar 2009 23:44:19 +0000 (+0100) Subject: first pickle, then save to avoid killing config file on sigint X-Git-Tag: 2.6.0~377^2~6 X-Git-Url: https://git.cweiske.de/enigma2.git/commitdiff_plain/533dd652737ca702c0e9528ed06e8a17b9ec72c5?hp=4a5818c82c71caa97447d4f91bd418a68c0bf174 first pickle, then save to avoid killing config file on sigint --- diff --git a/lib/python/Components/config.py b/lib/python/Components/config.py index 79e99b03..4cc40633 100755 --- a/lib/python/Components/config.py +++ b/lib/python/Components/config.py @@ -1614,8 +1614,9 @@ class Config(ConfigSubsection): self.setSavedValue(tree["config"]) def saveToFile(self, filename): + text = self.pickle() f = open(filename, "w") - f.write(self.pickle()) + f.write(text) f.close() def loadFromFile(self, filename):