summaryrefslogtreecommitdiffstats
path: root/include/backtrace/Backtrace.h
diff options
context:
space:
mode:
authorChristopher Ferris <cferris@google.com>2014-01-14 01:28:57 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2014-01-14 01:28:57 +0000
commit8791ee5c1486c9d6f9bf275bb096179dce95f309 (patch)
tree8c99eea97e3e6ad5c02db7c8721acbb786bc1cbb /include/backtrace/Backtrace.h
parent5b5b1f9b48f966942be3cda8d4ecfb7d910f12a0 (diff)
parent50fae736dc0a5552e9e14d8e8358449aa0f7536a (diff)
downloadsystem_core-8791ee5c1486c9d6f9bf275bb096179dce95f309.zip
system_core-8791ee5c1486c9d6f9bf275bb096179dce95f309.tar.gz
system_core-8791ee5c1486c9d6f9bf275bb096179dce95f309.tar.bz2
am 50fae736: am 1f71e465: am 68870199: Merge "Next phase of the move, reformat use C++ features."
* commit '50fae736dc0a5552e9e14d8e8358449aa0f7536a': Next phase of the move, reformat use C++ features.
Diffstat (limited to 'include/backtrace/Backtrace.h')
-rw-r--r--include/backtrace/Backtrace.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/backtrace/Backtrace.h b/include/backtrace/Backtrace.h
index bf4efd3..df40b87 100644
--- a/include/backtrace/Backtrace.h
+++ b/include/backtrace/Backtrace.h
@@ -60,6 +60,7 @@ public:
// Create a string representing the formatted line of backtrace information
// for a single frame.
virtual std::string FormatFrameData(size_t frame_num);
+ virtual std::string FormatFrameData(const backtrace_frame_data_t* frame);
pid_t Pid() { return backtrace_.pid; }
pid_t Tid() { return backtrace_.tid; }
@@ -68,9 +69,16 @@ public:
const backtrace_t* GetBacktrace() { return &backtrace_; }
const backtrace_frame_data_t* GetFrame(size_t frame_num) {
+ if (frame_num > NumFrames()) {
+ return NULL;
+ }
return &backtrace_.frames[frame_num];
}
+ const backtrace_map_info_t* GetMapList() {
+ return map_info_;
+ }
+
protected:
Backtrace(BacktraceImpl* impl, pid_t pid, backtrace_map_info_t* map_info);