Determination of frame boundaries corrected.

Sun, 10 Jan 2016 13:55:21 +0100

author
T.Rzepka <Tobias.Rzepka@gmail.com>
date
Sun, 10 Jan 2016 13:55:21 +0100
changeset 4683
1ba6ba86b383
parent 4651
7f3f276d3bf3
child 4684
ff9bce0e0424

Determination of frame boundaries corrected.

DebugClients/Python/DebugBase.py file | annotate | diff | comparison | revisions
DebugClients/Python3/DebugBase.py file | annotate | diff | comparison | revisions
--- a/DebugClients/Python/DebugBase.py	Sat Jan 09 19:44:31 2016 +0100
+++ b/DebugClients/Python/DebugBase.py	Sun Jan 10 13:55:21 2016 +0100
@@ -610,7 +610,11 @@
         if self._dbgClient.mainFrame is None:
             if fn != self._dbgClient.getRunning():
                 return
-            self._dbgClient.mainFrame = frame
+            fr = frame
+            while (fr is not None and
+                    fr.f_code != self._dbgClient.handleLine.func_code):
+                self._dbgClient.mainFrame = fr
+                fr = fr.f_back
 
         self.currentFrame = frame
         
--- a/DebugClients/Python3/DebugBase.py	Sat Jan 09 19:44:31 2016 +0100
+++ b/DebugClients/Python3/DebugBase.py	Sun Jan 10 13:55:21 2016 +0100
@@ -642,7 +642,11 @@
         if self._dbgClient.mainFrame is None:
             if fn != self._dbgClient.getRunning():
                 return
-            self._dbgClient.mainFrame = frame
+            fr = frame
+            while (fr is not None and
+                    fr.f_code != self._dbgClient.handleLine.__code__):
+                self._dbgClient.mainFrame = fr
+                fr = fr.f_back
 
         self.currentFrame = frame
         

eric ide

mercurial