[rtems-tools commit] rtemstoolkit/config: Unlock when printing to avoid blocking.

Chris Johns chrisj at rtems.org
Thu Feb 7 18:41:54 UTC 2019


Module:    rtems-tools
Branch:    master
Commit:    e6bf128eeade949c62ce3d213dfd57da72f08065
Changeset: http://git.rtems.org/rtems-tools/commit/?id=e6bf128eeade949c62ce3d213dfd57da72f08065

Author:    Chris Johns <chrisj at rtems.org>
Date:      Tue Feb  5 16:07:24 2019 +1100

rtemstoolkit/config: Unlock when printing to avoid blocking.

---

 tester/rt/config.py | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/tester/rt/config.py b/tester/rt/config.py
index 673c39b..457c0bd 100644
--- a/tester/rt/config.py
+++ b/tester/rt/config.py
@@ -46,6 +46,8 @@ from rtemstoolkit import execute
 from rtemstoolkit import log
 from rtemstoolkit import path
 
+from rtemstoolkit import stacktraces
+
 import console
 import gdb
 import tftp
@@ -341,7 +343,14 @@ class file(config.file):
 
     def _realtime_trace(self, text):
         for l in text:
-            print(''.join(l))
+            self._unlock()
+            try:
+                print(''.join(l))
+            except:
+                stacktraces.trace()
+                raise
+            finally:
+                self._lock()
 
     def run(self):
         self.target_start_regx = self._target_regex('target_start_regex')




More information about the vc mailing list