Mac:我得到SIGABRT,但是调用堆栈是无用的
Mac: I get SIGABRT but the call stack is useless
我正在用c++编写Mac游戏,并且我得到一个SIGABRT,并且控制台打印以下内容:
terminate called after throwing an instance of 'boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<boost::bad_lexical_cast> >'
what(): bad lexical cast: source type value could not be interpreted as target
Program received signal: “SIGABRT”.
所以,我做的lexical_cast很糟糕。但问题是,我不知道在哪里,因为调用堆栈如下:
#0 0x7fff85fb629a in mach_msg_trap
#1 0x7fff85fb690d in mach_msg
#2 0x7fff81f58932 in __CFRunLoopRun
#3 0x7fff81f57dbf in CFRunLoopRunSpecific
#4 0x7fff88dba7ee in RunCurrentEventLoopInMode
#5 0x7fff88dba5f3 in ReceiveNextEventCommon
#6 0x7fff88dba4ac in BlockUntilNextEventMatchingListInMode
#7 0x7fff84f85e64 in _DPSNextEvent
#8 0x7fff84f857a9 in -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:]
#9 0x7fff84f4b48b in -[NSApplication run]
#10 0x7fff84f441a8 in NSApplicationMain
#11 0x1000ef759 in os_gameMainLoop at main-osx.mm:22
#12 0x10009a97d in main at words.cpp:18
这不是正确的堆栈。
match_msg_trap是什么?
为什么我得到这个调用堆栈?
我有什么办法得到一个很好的调用堆栈吗?
谢谢!
调试器在错误的线程中停止。在GDB中尝试t a a bt
查看所有线程的回溯。
mach_msg_trap
是线程在等待消息进入时停留的地方。所以,你正在看一个没有运行的线程。Mach是OS x上消息传递接口的名称。
相关文章:
- Visual Studio(或任何其他工具)能否将地址解释为调用堆栈(boost上下文)的开头
- 为什么调用堆栈数组会导致内存泄漏
- 是否可以检查悬挂光纤的调用堆栈?
- MSVC __debugbreak() 与 openGL 错误回调一起使用时不会产生调用堆栈
- 以下代码如何工作以每次为唯一调用堆栈唯一实例化模板函数?
- OpenCV 3 Visual Studio 2017 调试,调用堆栈没有.pdb文件
- C/C++中全局调用堆栈的基础
- 是否可以访问代码中的调用堆栈?
- 调用堆栈显示 SIGBUS,这意味着什么
- 打开C++故障转储不会在调用堆栈中显示正确的行
- 将参数推送到调用堆栈 (C++) 的可移植方法
- 是否可以将功能调用堆栈放在堆上
- 未定义对调用堆栈库的引用出现问题
- 我无法获得由 Clang 构建的优化 NDK 应用程序的调用堆栈
- 调用堆栈中的访问冲突
- GDB正在调试一个缺少特定调用堆栈的符号表的核心转储
- C++按引用传递:如何使用调用堆栈
- 从系统调用内部生成调用堆栈
- 使用 .Net 4.0 时出现堆栈不平衡错误,但在使用 .Net 2.0 时不调用堆栈不平衡错误
- 生成所有可能的调用堆栈的树