当MB_ICONWARNING和MB_OK同时使用时,MessageBox API会导致访问冲突和崩溃

我遗留MFC应用程序使用VS2005迁移它VS2015 windows10没问题但是当测试的应用程序在windows 7应用程序崩溃时它显示一个消息框我发现应用程序不会崩溃,如果我删除ICONWARNING甚至累与其他旗帜图标像MB_ICONERROR我看到崩溃这也。

该模块是DLL而不是exe。

MessageBox(NULL,_T("Something"),_T("Some title"),MB_ICONWARNING|MB_OK); //crashes 
MessageBox(NULL,_T("Something"),_T("Some title"),MB_OK); //No Crash
Stack trace from the memory dump.
003ce974 7789fb56 00000000 00000000 776f6a2c ntdll!RtlpWaitOnCriticalSection+0xbd
003ce99c 748a5ea6 749cc618 0060e248 0060e240 ntdll!RtlEnterCriticalSection+0x150
003ce9b0 748a6000 0060e248 00020021 003ceaac comctl32!CImageList::_Destroy+0x51
003ce9cc 748a61e7 00000030 00000030 00020021 comctl32!CImageList::_Initialize+0x1b
003ce9f4 748da1fc 0060e260 00000030 00000030 comctl32!CImageList::Initialize+0x30
003cea38 748c8239 00a10253 00000028 00000028 comctl32!CreateSmallerIcon+0x9f
003cea68 7490f79c 02840001 00000054 00000028 comctl32!LoadIconWithScaleDown+0x109
003ceab4 74887fb2 0060a352 00000000 00000081 comctl32!CStatic::LoadImageW+0x10f
003ceb2c 7489780c 0005034e 00000001 00000000 comctl32!CStatic::WndProc+0x1bd
003ceb50 770086ef 0005034e 00000001 00000000 comctl32!CStatic::s_WndProc+0x8b
003ceb7c 770079cc 748977cd 0005034e 00000001 user32!InternalCallWinProc+0x23
003cebf4 770070f4 005a334c 748977cd 0005034e user32!UserCallWinProcCheckWow+0xe0
003cec50 77000b5f 00c79278 00000001 00000000 user32!DispatchClientMessage+0xda
003cec80 778b642e 003cec98 00000060 003cf39c user32!__fnINLPCREATESTRUCT+0x8b
003cecf4 77000d69 77000cfd 00000004 0000c019 ntdll!KiUserCallbackDispatcher+0x2e
003cecf8 77000cfd 00000004 0000c019 003ced48 user32!NtUserCreateWindowEx+0xc
003cef9c 76ff9a8a 00000004 0000c019 003ceff8 user32!VerNtUserCreateWindowEx+0x1a3
003cf078 77025500 76ff0000 00090346 00000000 user32!InternalCreateDialog+0xa4a
003cf0a8 7704e135 76ff0000 0060a2e0 00000000 user32!InternalDialogBox+0xa7
003cf14c 7704e6b9 00000030 68fdf948 00000000 user32!SoftModalMessageBox+0x68a
003cf29c 7704e7ec 003cf2a8 00000028 00000000 user32!MessageBoxWorker+0x2ca
003cf304 7704ea68 00000000 00607c80 00607de0 user32!MessageBoxTimeoutW+0x7f
003cf324 7704eb04 00000000 00607c80 00607de0 user32!MessageBoxExW+0x1b
003cf340 68f31dbf 00000000 00607c80 00607de0 user32!MessageBoxW+0x45

MODULE_NAME: comctl32

IMAGE_NAME: comctl32。dll

DEBUG_FLR_IMAGE_TIMESTAMP: 4 a5bd976

STACK_COMMAND: dt ntdll !LdrpLastDllInitializer BaseDllName;dt ntdll !LdrpFailureData;~ 0;。ecxr;kb

FAILURE_BUCKET_ID: NULL_CLASS_PTR_WRITE_c0000005_comctl32。dll !CImageList: _Destroy

BUCKET_ID: APPLICATION_FAULT_NULL_CLASS_PTR_WRITE_NULL_CLASS_PTR_DEREFERENCE_INVALID_POINTER_WRITE_comctl32 !CImageList: _Destroy + 51

FAILURE_EXCEPTION_CODE: c0000005

FAILURE_IMAGE_NAME: comctl32。dll

BUCKET_ID_IMAGE_STR: comctl32。dll

FAILURE_MODULE_NAME: comctl32

BUCKET_ID_MODULE_STR: comctl32

FAILURE_FUNCTION_NAME: CImageList:: _Destroy

BUCKET_ID_FUNCTION_STR: CImageList:: _Destroy

BUCKET_ID_OFFSET: 51

BUCKET_ID_MODTIMEDATESTAMP: 4 a5bd976

BUCKET_ID_MODCHECKSUM: 1 a1908

BUCKET_ID_MODVER_STR: 6。10。7600。16385

BUCKET_ID_PREFIX_STR: APPLICATION_FAULT_NULL_CLASS_PTR_WRITE_NULL_CLASS_PTR_DEREFERENCE_INVALID_POINTER_WRITE_

FAILURE_PROBLEM_CLASS: APPLICATION_FAULT

FAILURE_SYMBOL_NAME: comctl32。dll !CImageList: _Destroy

WATSON_STAGEONE_URL: http://watson。microsoft。com/StageOne/ABT。exe/2。9。13。7/6110c135/ntdll。dll/6。1。7600。16385/4a5bdadb/c0000005/0002fc47。htm?Retriage=1

TARGET_TIME: 2021 - 08 - 10 - t10:52:43。000z

OSBUILD: 7600

OSSERVICEPACK: 16385

SERVICEPACK_NUMBER: 0

OS_REVISION: 0

OSPLATFORM_TYPE: x86

OSNAME: Windows 7

Windows 7 WinNt SingleUserTS

USER_LCID: 0

OSBUILD_TIMESTAMP: 2009-07-14 06:39:01

BUILDDATESTAMP_STR: 090713 - 1255

BUILDLAB_STR: win7_rtm

BUILDOSVER_STR: 6。1。7600。16385

ANALYSIS_SESSION_ELAPSED_TIME: f8b

ANALYSIS_SOURCE:嗯

FAILURE_ID_HASH_STRING:嗯:null_class_ptr_write_c0000005_comctl32。dll !cimagelist: _destroy

FAILURE_ID_HASH: {b3bc3c2c-d915-6f2d-661c-984cc3a945f1}


Thank you for looking to this, appreciate any inputs or suggestions.
阅读全文

▼ 版权说明

相关文章也很精彩
推荐内容
更多标签
相关热门
全站排行
随便看看

错说 cuoshuo.com —— 程序员的报错记录

部分内容根据CC版权协议转载;网站内容仅供参考,生产环境使用务必查阅官方文档

辽ICP备19011660号-5

×

扫码关注公众号:职场神器
发送: 1
获取永久解锁本站全部文章的验证码