author | Laurent Bessard |
Sun, 23 Sep 2012 23:34:04 +0200 | |
changeset 841 | 8e19df12b596 |
parent 840 | 980863738cf6 |
child 842 | 3c4c1e076a34 |
ConfigTreeNode.py | file | annotate | diff | comparison | revisions |
--- a/ConfigTreeNode.py Sun Sep 23 18:57:35 2012 +0200 +++ b/ConfigTreeNode.py Sun Sep 23 23:34:04 2012 +0200 @@ -353,10 +353,12 @@ # Find a free name, eventually appending digit res = DesiredName if DesiredName.endswith("_0"): - DesiredName = DesiredName[:-2] + BaseDesiredName = DesiredName[:-2] + else: + BaseDesiredName = DesiredName suffix = 1 while res in AllNames: - res = "%s_%d"%(DesiredName, suffix) + res = "%s_%d"%(BaseDesiredName, suffix) suffix += 1 # Get old path