Skip to content

Commit 1e86cf5

Browse files
committed
fix error in pncconf when there is no preference file
the first time you run pncconf there is no preference file, that caused an error and pncconf would not continue.
1 parent da90659 commit 1e86cf5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: src/emc/usr_intf/pncconf/pncconf.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -3071,6 +3071,7 @@ def __init__(self):
30713071
self.data[i] = int(self.widgets[cb].child.connect("activate", self.on_general_pin_changed,"parport",connector,"Opin",pin,True))
30723072

30733073
# set preferences if they exist
3074+
link = short = False
30743075
filename = os.path.expanduser("~/.pncconf-preferences")
30753076
if os.path.exists(filename):
30763077
match = open(filename).read()
@@ -3080,7 +3081,6 @@ def __init__(self):
30803081
textbuffer.insert_at_cursor(match)
30813082
except:
30823083
pass
3083-
link = short = False
30843084
version = 0.0
30853085
d = xml.dom.minidom.parse(open(filename, "r"))
30863086
for n in d.getElementsByTagName("property"):

0 commit comments

Comments
 (0)