Fix bug in debugger when transfer without having build before and and opening debug view before running PLC
authorlaurent
Tue, 27 Mar 2012 23:59:35 +0200
changeset 661 7891872e6fd7
parent 660 30c0371ac086
child 662 3c4e0d4f7a61
Fix bug in debugger when transfer without having build before and and opening debug view before running PLC
PLCControler.py
--- a/PLCControler.py	Tue Mar 27 23:57:51 2012 +0200
+++ b/PLCControler.py	Tue Mar 27 23:59:35 2012 +0200
@@ -550,7 +550,10 @@
         return self.CurrentCompiledProject is not None
 
     def ProgramTransferred(self):
-        self.CurrentCompiledProject = self.NextCompiledProject
+        if self.NextCompiledProject is None:
+            self.CurrentCompiledProject = self.NextCompiledProject
+        else:
+            self.CurrentCompiledProject = self.Copy(self.Project)
 
     def GetChunkInfos(self, from_location, to_location):
         row = self.ProgramOffset + 1