我在我的应用程序中观察到崩溃,调用堆栈如下所示
mfc42u!CString::AllocBeforeWrite+5
mfc42u!CString::operator=+22
不知道为什么会这样。这也不经常发生。任何建议都会有所帮助。我有崩溃转储,但无法进一步取得进展。
我正在执行的操作是这样的
iParseErr += m_RawMessage[wMsgLen-32] != NC_SP;
其中 m_RawMessage 是一个 512 长度的字符数组。wMsgLen 是 unsigned short 并且 NC_SP 定义为
#define NC_SP 0x20 // Space
编辑:
调用堆栈:
042afe3c 5f8090dd mfc42u!CString::AllocBeforeWrite+0x5 * WARNING: Unable to verify checksum for WP Communications Server.exe
042afe50 0045f0c0 mfc42u!CString::operator=+0x22
042aff10 5f814d6b WP_Communications_Server!CParserN1000::iCheckMessage(void)+0x665 [V:\CSAC\SourceCode\WP Communications Server\HW Parser N1000.cpp @ 1279]
042aff80 77c3a3b0 mfc42u!_AfxThreadEntry+0xe6
042affb4 7c80b729 msvcrt!_endthreadex+0xa9
042affec 00000000 kernel32!BaseThreadStart+0x37
嗯,这是完整的调用堆栈,我已经发布了代码片段,就像我原来的消息一样
谢谢