Resolve the type undefined property
authorduplo <duplo@38d2e660-2303-0410-9eaa-f027e97ec537>
Fri, 6 Feb 2009 16:29:08 +0000 (16:29 +0000)
committerduplo <duplo@38d2e660-2303-0410-9eaa-f027e97ec537>
Fri, 6 Feb 2009 16:29:08 +0000 (16:29 +0000)
git-svn-id: https://src.develer.com/svnoss/bertos/trunk@2308 38d2e660-2303-0410-9eaa-f027e97ec537

wizard/bertos_utils.py

index cbec405d88d86d6d1289cd3dcb99c1a9ba005ccc..925774ba387fefe0761b66364763fb40c9a8bc9d 100644 (file)
@@ -212,10 +212,14 @@ def loadConfigurationInfos(path):
             configurationInfos[name] = {}
             configurationInfos[name]["value"] = value
             configurationInfos[name]["informations"] = informations
-            if configurationInfos[name]["informations"]["type"] == "int" and configurationInfos[name]["value"].find("L") != -1:
+            if ("type" in configurationInfos[name]["informations"].keys() and
+                    configurationInfos[name]["informations"]["type"] == "int" and
+                    configurationInfos[name]["value"].find("L") != -1):
                 configurationInfos[name]["informations"]["long"] = True
                 configurationInfos[name]["value"] = configurationInfos[name]["value"].replace("L", "")
-            if configurationInfos[name]["informations"]["type"] == "int" and configurationInfos[name]["value"].find("U") != -1:
+            if ("type" in configurationInfos[name]["informations"].keys() and
+                    configurationInfos[name]["informations"]["type"] == "int" and
+                    configurationInfos[name]["value"].find("U") != -1):
                 configurationInfos[name]["informations"]["unsigned"] = True
                 configurationInfos[name]["value"] = configurationInfos[name]["value"].replace("U", "")
             configurationInfos[name]["description"] = description