添加崩溃调用栈使用说明
This commit is contained in:
parent
5f5cb4ede1
commit
1a9acafbde
@ -1,3 +1,11 @@
|
||||
/*
|
||||
* 只使用GCC编译时,则使用 -g -rdynamic选项
|
||||
* CMake项目需分别使用add_compile_options(-g) add_link_options(-rdynamic)
|
||||
* 否则获取调用栈时不能得到函数名
|
||||
* 该配置仅支持GCC+Linux平台
|
||||
*/
|
||||
#include <execinfo.h>
|
||||
|
||||
QString WriteStackTrace(const QString &aStackTrace)
|
||||
{
|
||||
QString path = QDir::homePath() + "/.local/share/spark-store/crash/";
|
||||
|
Loading…
Reference in New Issue
Block a user