From 15740faf9fe9fe4be08965098bbf2947e096aeeb Mon Sep 17 00:00:00 2001 From: chai Date: Wed, 14 Aug 2019 22:50:43 +0800 Subject: +Unity Runtime code --- Runtime/Utilities/Stacktrace.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 Runtime/Utilities/Stacktrace.h (limited to 'Runtime/Utilities/Stacktrace.h') diff --git a/Runtime/Utilities/Stacktrace.h b/Runtime/Utilities/Stacktrace.h new file mode 100644 index 0000000..7344e91 --- /dev/null +++ b/Runtime/Utilities/Stacktrace.h @@ -0,0 +1,12 @@ +#ifndef STACKTRACE_H +#define STACKTRACE_H + +void InitializeStackWalker(); + +std::string GetStacktrace(bool includeMonoStackFrames = false); + +//can't use string version when debugging new/delete allocations, as string class may allocate memory itself! +void GetStacktrace(char *trace, int maxSize, int maxFrames = INT_MAX); +UInt32 GetStacktrace(void** trace, int maxFrames, int startframe); +void GetReadableStackTrace(char* output, int bufsize, void** input, int count); +#endif -- cgit v1.1-26-g67d0