summaryrefslogtreecommitdiffstats
path: root/rtemstoolkit/stacktraces.py
diff options
context:
space:
mode:
Diffstat (limited to 'rtemstoolkit/stacktraces.py')
-rw-r--r--rtemstoolkit/stacktraces.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/rtemstoolkit/stacktraces.py b/rtemstoolkit/stacktraces.py
index e589618..dc1dbad 100644
--- a/rtemstoolkit/stacktraces.py
+++ b/rtemstoolkit/stacktraces.py
@@ -1,6 +1,6 @@
#
# RTEMS Tools Project (http://www.rtems.org/)
-# Copyright 2013-2014 Chris Johns (chrisj@rtems.org)
+# Copyright 2013-2016 Chris Johns (chrisj@rtems.org)
# All rights reserved.
#
# This file is part of the RTEMS Tools package in 'rtems-tools'.
@@ -33,11 +33,10 @@ import traceback
def trace():
code = []
- for threadId, stack in sys._current_frames().items():
+ for threadId, stack in list(sys._current_frames().items()):
code.append("\n# thread-id: %s" % threadId)
for filename, lineno, name, line in traceback.extract_stack(stack):
code.append('file: "%s", line %d, in %s' % (filename, lineno, name))
if line:
code.append(" %s" % (line.strip()))
return '\n'.join(code)
-