#0 0xffffe410 in __kernel_vsyscall () #1 0x008e2df0 in __libc_start_main () from /lib/libc.so.6 #2 0x008e4701 in __gconv_close () from /lib/libc.so.6 #3 0x00919bcb in _IO_vfscanf_internal () from /lib/libc.so.6 #4 0x009203f6 in _IO_vfwscanf () from /lib/libc.so.6 scanf,sscanf #5 0x00922657 in _IO_vfwscanf () from /lib/libc.so.6 #6 0x009247d7 in __parse_one_specwc () from /lib/libc.so.6 printf-parse.h #7 0x00600b87 in operator new(unsigned int, std::nothrow_t const&) () from /usr/lib/libstdc++.so.6 #8 0x55b342fd in RtmpServerLive::PublishTo (this=0x9561cc0, strIp=..., port=1935, strApp=..., strStream=...) at ../RtmpServerLive.cpp:620 #9 0x55b36cbb in RtmpServerLive::Do (this=0x9561cc0, cmd=..., bHaveReturn=@0xffb9cabf, returnValue=...) at ../RtmpServerLive.cpp:67 #10 0x55b478e8 in RtmpServerLiveInterfaceReg::Do (args=...) at ../RtmpServerLiveInterfaceReg.cpp:264 #11 0x4a8dff33 in ?? () #12 0xffb9cb18 in ?? () #13 0xffb9cb08 in ?? () #14 0xffb9cb3c in ?? () #15 0xffb9cb40 in ?? () #16 0x00000001 in ?? () #17 0x00000000 in ?? ()
core中调用堆栈如上,这是c++写的模块供nodejs调用,程序在不定时候崩溃。总觉得这个调用堆栈奇怪,在使用vasprintf格式化数据时崩溃,可是,堆栈显示 最后跳入__libc_start_main (),按我的理解,这是c程序进程启动时入口。 这个堆栈是否有问题,程序是否是跑飞了,(内存越界访问?) 另,张老师有没有调试c++内存越界的案例,内存越界通常会有什么引起的?
|