Why doesn't the WM_DESTROY case handle this properly? At first glance, it appears to have code for stopping the running applets and quitting from the main loop.
Calling ExitProcess from WM_CLOSE is anything but graceful.
Vincent Povirk
On Thu, Aug 21, 2008 at 2:25 PM, Steven Edwards winehacker@gmail.com wrote:
This time without the TAB/space mixup
Without this patch, if you have the Control Panel window open along with an applet and you try to close the Panel window, you get a very nice crash. This forces an exit with a little grace
Changelog: shell32 - handle WM_CLOSE in the Control Panel window
-- Steven Edwards
"There is one thing stronger than all the armies in the world, and that is an idea whose time has come." - Victor Hugo
On Thu, Aug 21, 2008 at 9:00 PM, Vincent Povirk madewokherd+8cd9@gmail.com wrote:
Why doesn't the WM_DESTROY case handle this properly? At first glance, it appears to have code for stopping the running applets and quitting from the main loop.
Calling ExitProcess from WM_CLOSE is anything but graceful.
I am not sure what the right answer is as I've never really tried to fix this type of problem before, WM_DESTROY does not seem to do something right, as even making WM_CLOSE fall through to it produces the same crash. I spent some time trying to debug the problem but got no where so I started just blindly adding PostQuitMessages and ExitProcess calls around the areas in the backtrace until I found something that got rid of the crash. Its easy to replicate, just run control, open the appwiz.cpl and then close the control panel window with the cpl applet still open.
Here is the backtrace
wine: Unhandled page fault on execute access to 0x7e50da00 at address 0x7e50da00 (thread 0009), starting debugger... Unhandled exception: page fault on execute access to 0x7e50da00 in 32-bit code (0x7e50da00). Register dump: CS:0023 SS:002b DS:002b ES:002b FS:0063 GS:006b EIP:7e50da00 ESP:0033b57c EBP:0033b5a8 EFLAGS:00010206( - 00 - RIP1) EAX:7e50da00 EBX:7eba0574 ECX:00000000 EDX:7e50da00 ESI:00000000 EDI:0001003a Stack dump: 0x0033b57c: 7eb7d8da 0001003a 00000018 00000000 0x0033b58c: 00000000 7ebbfe80 7eba0574 0033b5a8 0x0033b59c: 7eba0574 00000000 0001003a 0033b5e8 0x0033b5ac: 7eb7f738 7e50da00 0001003a 00000018 0x0033b5bc: 00000000 00000000 00000000 0033b5d8 0x0033b5cc: 7eb6f120 7ebbfe80 7eba0574 7eb7f6db Backtrace: =>1 0x7e50da00 (0x0033b5a8) 2 0x7eb7f738 call_dialog_proc+0x68(hwnd=<register EDI not in topmost frame>, msg=0x18, wp=0x0, lp=0x0, result=0x33b618, arg=0x7e50da00) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:479] in user32 (0x0033b5e8) 3 0x7eb82f5a WINPROC_CallDlgProcW+0x5a(func=0xffff0026, hwnd=0x1003a, msg=0x18, wParam=<register EDI not in topmost frame>, lParam=0x0) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2394] in user32 (0x0033b628) 4 0x7eb0a2d5 DefDlgProcW+0x85(hwnd=<register ESI not in topmost frame>, msg=0x18, wParam=0x0, lParam=0x0) [/home/sedwards/source/wine-git/dlls/user32/defdlg.c:488] in user32 (0x0033b658) 5 0x7eb7d8da WINPROC_wrapper+0x1a() in user32 (0x0033b688) 6 0x7eb7dfce call_window_proc+0x6e(hwnd=<register EDI not in topmost frame>, msg=0x18, wp=0x0, lp=0x0, result=0x33b76c, arg=0x7eb0a250) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:457] in user32 (0x0033b6c8) 7 0x7eb842f1 WINPROC_call_window+0xd1(hwnd=<register ESI not in topmost frame>, msg=0x18, wParam=0x0, lParam=0x0, result=0x33b76c, unicode=0x1, mapping=0x1) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2207] in user32 (0x0033b708) 8 0x7eb458ca call_window_proc+0xca(hwnd=<register ESI not in topmost frame>, msg=0x18, wparam=0x0, lparam=0x0, unicode=0x1, same_thread=0x1, mapping=0x1) [/home/sedwards/source/wine-git/dlls/user32/message.c:1639] in user32 (0x0033b778) 9 0x7eb48862 send_message+0x222(info=<register EDI not in topmost frame>, res_ptr=0x33b814, unicode=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/message.c:2463] in user32 (0x0033b7d8) 10 0x7eb48cda SendMessageW+0x4a(hwnd=0x1003a, msg=0x18, wparam=0x0, lparam=0x0) [/home/sedwards/source/wine-git/dlls/user32/message.c:2586] in user32 (0x0033b818) 11 0x7eb7cd06 show_window+0x4d6(hwnd=0x1003a, cmd=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/winpos.c:1046] in user32 (0x0033b888) 12 0x7eb7ce4b ShowWindow+0x3b(hwnd=<register ESI not in topmost frame>, cmd=0x0) [/home/sedwards/source/wine-git/dlls/user32/winpos.c:1154] in user32 (0x0033b8a8) 13 0x7eb724fc DestroyWindow+0x1bc(hwnd=0x1003a) [/home/sedwards/source/wine-git/dlls/user32/win.c:1502] in user32 (0x0033b8e8) 14 0x7ea4e49b PROPSHEET_CleanUp+0xcb(hwndDlg=<is not available>) [/home/sedwards/source/wine-git/dlls/comctl32/propsheet.c:2720] in comctl32 (0x0033b918) 15 0x7ea51ef5 PROPSHEET_DialogProc+0x595(hwnd=0x1002e, uMsg=<register ESI not in topmost frame>, wParam=0x0, lParam=0x0) [/home/sedwards/source/wine-git/dlls/comctl32/propsheet.c:3534] in comctl32 (0x0033bc48) 16 0x7eb7d8da WINPROC_wrapper+0x1a() in user32 (0x0033bc78) 17 0x7eb7f738 call_dialog_proc+0x68(hwnd=<register EDI not in topmost frame>, msg=0x2, wp=0x0, lp=0x0, result=0x33bce8, arg=0x7ea51960) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:479] in user32 (0x0033bcb8) 18 0x7eb82f5a WINPROC_CallDlgProcW+0x5a(func=0xffff0025, hwnd=0x1002e, msg=0x2, wParam=<register EDI not in topmost frame>, lParam=0x0) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2394] in user32 (0x0033bcf8) 19 0x7eb0a2d5 DefDlgProcW+0x85(hwnd=<register ESI not in topmost frame>, msg=0x2, wParam=0x0, lParam=0x0) [/home/sedwards/source/wine-git/dlls/user32/defdlg.c:488] in user32 (0x0033bd28) 20 0x7eb7d8da WINPROC_wrapper+0x1a() in user32 (0x0033bd58) 21 0x7eb7dfce call_window_proc+0x6e(hwnd=<register EDI not in topmost frame>, msg=0x2, wp=0x0, lp=0x0, result=0x33be3c, arg=0x7eb0a250) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:457] in user32 (0x0033bd98) 22 0x7eb842f1 WINPROC_call_window+0xd1(hwnd=<register ESI not in topmost frame>, msg=0x2, wParam=0x0, lParam=0x0, result=0x33be3c, unicode=0x1, mapping=0x1002e) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2207] in user32 (0x0033bdd8) 23 0x7eb458ca call_window_proc+0xca(hwnd=<register ESI not in topmost frame>, msg=0x2, wparam=0x0, lparam=0x0, unicode=0x1, same_thread=0x1, mapping=0x1002e) [/home/sedwards/source/wine-git/dlls/user32/message.c:1639] in user32 (0x0033be48) 24 0x7eb48862 send_message+0x222(info=<register EDI not in topmost frame>, res_ptr=0x33bee4, unicode=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/message.c:2463] in user32 (0x0033bea8) 25 0x7eb48cda SendMessageW+0x4a(hwnd=0x1002e, msg=0x2, wparam=0x0, lparam=0x0) [/home/sedwards/source/wine-git/dlls/user32/message.c:2586] in user32 (0x0033bee8) 26 0x7eb71186 WIN_SendDestroyMsg+0x66(hwnd=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/win.c:1436] in user32 (0x0033bf48) 27 0x7eb72521 DestroyWindow+0x1e1(hwnd=0x1002e) [/home/sedwards/source/wine-git/dlls/user32/win.c:1540] in user32 (0x0033bf88) 28 0x7ea4f8a0 PROPSHEET_PropertySheet+0x2c0(psInfo=0x1381c0, unicode=<is not available>) [/home/sedwards/source/wine-git/dlls/comctl32/propsheet.c:2803] in comctl32 (0x0033bfe8) 29 0x7ea500cf PropertySheetW+0x1cf(lppsh=0x33d080) [/home/sedwards/source/wine-git/dlls/comctl32/propsheet.c:2900] in comctl32 (0x0033c058) 30 0x7e50c930 (0x0033d0f8) 31 0x7ed7e3cd Control_WndProc+0xa3d(hWnd=0x10026, wMsg=0x4e, lParam1=0x3e8, lParam2=0x33e4a0) [/home/sedwards/source/wine-git/dlls/shell32/control.c:501] in shell32 (0x0033e238) 32 0x7eb7d8da WINPROC_wrapper+0x1a() in user32 (0x0033e268) 33 0x7eb7dfce call_window_proc+0x6e(hwnd=<register EDI not in topmost frame>, msg=0x4e, wp=0x3e8, lp=0x33e4a0, result=0x33e34c, arg=0x7ed7d990) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:457] in user32 (0x0033e2a8) 34 0x7eb842f1 WINPROC_call_window+0xd1(hwnd=<register ESI not in topmost frame>, msg=0x4e, wParam=0x3e8, lParam=0x33e4a0, result=0x33e34c, unicode=0x1, mapping=0x1) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2207] in user32 (0x0033e2e8) 35 0x7eb458ca call_window_proc+0xca(hwnd=<register ESI not in topmost frame>, msg=0x4e, wparam=0x3e8, lparam=0x33e4a0, unicode=0x1, same_thread=0x1, mapping=0x1) [/home/sedwards/source/wine-git/dlls/user32/message.c:1639] in user32 (0x0033e358) 36 0x7eb48862 send_message+0x222(info=<register EDI not in topmost frame>, res_ptr=0x33e3f4, unicode=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/message.c:2463] in user32 (0x0033e3b8) 37 0x7eb48cda SendMessageW+0x4a(hwnd=0x10026, msg=0x4e, wparam=0x3e8, lparam=0x33e4a0) [/home/sedwards/source/wine-git/dlls/user32/message.c:2586] in user32 (0x0033e3f8) 38 0x7ea2b89b notify_hdr+0x6b(infoPtr=<register EDI not in topmost frame>, code=0xfffffffd, pnmh=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/comctl32/listview.c:737] in comctl32 (0x0033e428) 39 0x7ea3364f notify_click+0x16f(infoPtr=0x1337e8, code=0xfffffffd, lvht=0x33e578) [/home/sedwards/source/wine-git/dlls/comctl32/listview.c:806] in comctl32 (0x0033e4d8) 40 0x7ea33955 LISTVIEW_LButtonDblClk+0xa5(infoPtr=<register EDI not in topmost frame>, wKey=<is not available>, x=0x28, y=0x15) [/home/sedwards/source/wine-git/dlls/comctl32/listview.c:8557] in comctl32 (0x0033e598) 41 0x7ea3ecbe LISTVIEW_WindowProc+0x3de(hwnd=0x1002a, uMsg=0x203, wParam=0x1, lParam=0x15) [/home/sedwards/source/wine-git/dlls/comctl32/listview.c:9926] in comctl32 (0x0033ee98) 42 0x7eb7d8da WINPROC_wrapper+0x1a() in user32 (0x0033eec8) 43 0x7eb7dfce call_window_proc+0x6e(hwnd=<register EDI not in topmost frame>, msg=0x203, wp=0x1, lp=0x150028, result=0x33ef78, arg=0x7ea3e8e0) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:457] in user32 (0x0033ef08) 44 0x7eb842f1 WINPROC_call_window+0xd1(hwnd=<register ESI not in topmost frame>, msg=0x203, wParam=0x1, lParam=0x150028, result=0x33ef78, unicode=0x1, mapping=0x4) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2207] in user32 (0x0033ef48) 45 0x7eb45186 DispatchMessageW+0x96(msg=<register EDI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/message.c:3125] in user32 (0x0033ef88) 46 0x7ed7f177 Control_RunDLLW+0x3f7(hWnd=0x10020, hInst=0x0, cmd=0x1326f0, nCmdShow=0x5) [/home/sedwards/source/wine-git/dlls/shell32/control.c:620] in shell32 (0x0033fcc8) 47 0x7ed7f76d Control_RunDLLA+0xfd(hWnd=0x10020, hInst=0x0, cmd=0x7ee7eb43, nCmdShow=0x5) [/home/sedwards/source/wine-git/dlls/shell32/control.c:825] in shell32 (0x0033fcf8) 48 0x7ee7e5ea launch+0x3a(what=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/programs/control/control.c:31] in control (0x0033fd18) 49 0x7ee7e665 WinMain+0x65(hInst=0x7ee70000, hPrev=0x0, lpszCmdLine=0x110860, nCmdShow=0x1) [/home/sedwards/source/wine-git/programs/control/control.c:70] in control (0x0033fe58) 50 0x7ee7e963 main+0xa3() [/home/sedwards/source/wine-git/dlls/winecrt0/exe_main.c:48] in control (0x0033fed8) 51 0x7ee7e88b __wine_spec_exe_entry+0x5b(peb=0x7ffdf000) [/home/sedwards/source/wine-git/dlls/winecrt0/exe_entry.c:36] in control (0x0033ff08) 52 0x7b877ef7 start_process+0xc7(arg=0x0) [/home/sedwards/source/wine-git/dlls/kernel32/process.c:904] in kernel32 (0x0033ffe8)
Commenting out FreeLibrary(applet->hModule); in Control_UnloadApplet avoids the crash. The problem is that the applet's dialog still exists when FreeLibrary is called. Since its dialog procedure was in the freed library, the program crashes when that dialog gets a message.
I don't know what the proper fix is.
Vincent Povirk
On Thu, Aug 21, 2008 at 9:26 PM, Steven Edwards winehacker@gmail.com wrote:
On Thu, Aug 21, 2008 at 9:00 PM, Vincent Povirk madewokherd+8cd9@gmail.com wrote:
Why doesn't the WM_DESTROY case handle this properly? At first glance, it appears to have code for stopping the running applets and quitting from the main loop.
Calling ExitProcess from WM_CLOSE is anything but graceful.
I am not sure what the right answer is as I've never really tried to fix this type of problem before, WM_DESTROY does not seem to do something right, as even making WM_CLOSE fall through to it produces the same crash. I spent some time trying to debug the problem but got no where so I started just blindly adding PostQuitMessages and ExitProcess calls around the areas in the backtrace until I found something that got rid of the crash. Its easy to replicate, just run control, open the appwiz.cpl and then close the control panel window with the cpl applet still open.
Here is the backtrace
wine: Unhandled page fault on execute access to 0x7e50da00 at address 0x7e50da00 (thread 0009), starting debugger... Unhandled exception: page fault on execute access to 0x7e50da00 in 32-bit code (0x7e50da00). Register dump: CS:0023 SS:002b DS:002b ES:002b FS:0063 GS:006b EIP:7e50da00 ESP:0033b57c EBP:0033b5a8 EFLAGS:00010206( - 00 - RIP1) EAX:7e50da00 EBX:7eba0574 ECX:00000000 EDX:7e50da00 ESI:00000000 EDI:0001003a Stack dump: 0x0033b57c: 7eb7d8da 0001003a 00000018 00000000 0x0033b58c: 00000000 7ebbfe80 7eba0574 0033b5a8 0x0033b59c: 7eba0574 00000000 0001003a 0033b5e8 0x0033b5ac: 7eb7f738 7e50da00 0001003a 00000018 0x0033b5bc: 00000000 00000000 00000000 0033b5d8 0x0033b5cc: 7eb6f120 7ebbfe80 7eba0574 7eb7f6db Backtrace: =>1 0x7e50da00 (0x0033b5a8) 2 0x7eb7f738 call_dialog_proc+0x68(hwnd=<register EDI not in topmost frame>, msg=0x18, wp=0x0, lp=0x0, result=0x33b618, arg=0x7e50da00) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:479] in user32 (0x0033b5e8) 3 0x7eb82f5a WINPROC_CallDlgProcW+0x5a(func=0xffff0026, hwnd=0x1003a, msg=0x18, wParam=<register EDI not in topmost frame>, lParam=0x0) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2394] in user32 (0x0033b628) 4 0x7eb0a2d5 DefDlgProcW+0x85(hwnd=<register ESI not in topmost frame>, msg=0x18, wParam=0x0, lParam=0x0) [/home/sedwards/source/wine-git/dlls/user32/defdlg.c:488] in user32 (0x0033b658) 5 0x7eb7d8da WINPROC_wrapper+0x1a() in user32 (0x0033b688) 6 0x7eb7dfce call_window_proc+0x6e(hwnd=<register EDI not in topmost frame>, msg=0x18, wp=0x0, lp=0x0, result=0x33b76c, arg=0x7eb0a250) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:457] in user32 (0x0033b6c8) 7 0x7eb842f1 WINPROC_call_window+0xd1(hwnd=<register ESI not in topmost frame>, msg=0x18, wParam=0x0, lParam=0x0, result=0x33b76c, unicode=0x1, mapping=0x1) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2207] in user32 (0x0033b708) 8 0x7eb458ca call_window_proc+0xca(hwnd=<register ESI not in topmost frame>, msg=0x18, wparam=0x0, lparam=0x0, unicode=0x1, same_thread=0x1, mapping=0x1) [/home/sedwards/source/wine-git/dlls/user32/message.c:1639] in user32 (0x0033b778) 9 0x7eb48862 send_message+0x222(info=<register EDI not in topmost frame>, res_ptr=0x33b814, unicode=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/message.c:2463] in user32 (0x0033b7d8) 10 0x7eb48cda SendMessageW+0x4a(hwnd=0x1003a, msg=0x18, wparam=0x0, lparam=0x0) [/home/sedwards/source/wine-git/dlls/user32/message.c:2586] in user32 (0x0033b818) 11 0x7eb7cd06 show_window+0x4d6(hwnd=0x1003a, cmd=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/winpos.c:1046] in user32 (0x0033b888) 12 0x7eb7ce4b ShowWindow+0x3b(hwnd=<register ESI not in topmost frame>, cmd=0x0) [/home/sedwards/source/wine-git/dlls/user32/winpos.c:1154] in user32 (0x0033b8a8) 13 0x7eb724fc DestroyWindow+0x1bc(hwnd=0x1003a) [/home/sedwards/source/wine-git/dlls/user32/win.c:1502] in user32 (0x0033b8e8) 14 0x7ea4e49b PROPSHEET_CleanUp+0xcb(hwndDlg=<is not available>) [/home/sedwards/source/wine-git/dlls/comctl32/propsheet.c:2720] in comctl32 (0x0033b918) 15 0x7ea51ef5 PROPSHEET_DialogProc+0x595(hwnd=0x1002e, uMsg=<register ESI not in topmost frame>, wParam=0x0, lParam=0x0) [/home/sedwards/source/wine-git/dlls/comctl32/propsheet.c:3534] in comctl32 (0x0033bc48) 16 0x7eb7d8da WINPROC_wrapper+0x1a() in user32 (0x0033bc78) 17 0x7eb7f738 call_dialog_proc+0x68(hwnd=<register EDI not in topmost frame>, msg=0x2, wp=0x0, lp=0x0, result=0x33bce8, arg=0x7ea51960) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:479] in user32 (0x0033bcb8) 18 0x7eb82f5a WINPROC_CallDlgProcW+0x5a(func=0xffff0025, hwnd=0x1002e, msg=0x2, wParam=<register EDI not in topmost frame>, lParam=0x0) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2394] in user32 (0x0033bcf8) 19 0x7eb0a2d5 DefDlgProcW+0x85(hwnd=<register ESI not in topmost frame>, msg=0x2, wParam=0x0, lParam=0x0) [/home/sedwards/source/wine-git/dlls/user32/defdlg.c:488] in user32 (0x0033bd28) 20 0x7eb7d8da WINPROC_wrapper+0x1a() in user32 (0x0033bd58) 21 0x7eb7dfce call_window_proc+0x6e(hwnd=<register EDI not in topmost frame>, msg=0x2, wp=0x0, lp=0x0, result=0x33be3c, arg=0x7eb0a250) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:457] in user32 (0x0033bd98) 22 0x7eb842f1 WINPROC_call_window+0xd1(hwnd=<register ESI not in topmost frame>, msg=0x2, wParam=0x0, lParam=0x0, result=0x33be3c, unicode=0x1, mapping=0x1002e) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2207] in user32 (0x0033bdd8) 23 0x7eb458ca call_window_proc+0xca(hwnd=<register ESI not in topmost frame>, msg=0x2, wparam=0x0, lparam=0x0, unicode=0x1, same_thread=0x1, mapping=0x1002e) [/home/sedwards/source/wine-git/dlls/user32/message.c:1639] in user32 (0x0033be48) 24 0x7eb48862 send_message+0x222(info=<register EDI not in topmost frame>, res_ptr=0x33bee4, unicode=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/message.c:2463] in user32 (0x0033bea8) 25 0x7eb48cda SendMessageW+0x4a(hwnd=0x1002e, msg=0x2, wparam=0x0, lparam=0x0) [/home/sedwards/source/wine-git/dlls/user32/message.c:2586] in user32 (0x0033bee8) 26 0x7eb71186 WIN_SendDestroyMsg+0x66(hwnd=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/win.c:1436] in user32 (0x0033bf48) 27 0x7eb72521 DestroyWindow+0x1e1(hwnd=0x1002e) [/home/sedwards/source/wine-git/dlls/user32/win.c:1540] in user32 (0x0033bf88) 28 0x7ea4f8a0 PROPSHEET_PropertySheet+0x2c0(psInfo=0x1381c0, unicode=<is not available>) [/home/sedwards/source/wine-git/dlls/comctl32/propsheet.c:2803] in comctl32 (0x0033bfe8) 29 0x7ea500cf PropertySheetW+0x1cf(lppsh=0x33d080) [/home/sedwards/source/wine-git/dlls/comctl32/propsheet.c:2900] in comctl32 (0x0033c058) 30 0x7e50c930 (0x0033d0f8) 31 0x7ed7e3cd Control_WndProc+0xa3d(hWnd=0x10026, wMsg=0x4e, lParam1=0x3e8, lParam2=0x33e4a0) [/home/sedwards/source/wine-git/dlls/shell32/control.c:501] in shell32 (0x0033e238) 32 0x7eb7d8da WINPROC_wrapper+0x1a() in user32 (0x0033e268) 33 0x7eb7dfce call_window_proc+0x6e(hwnd=<register EDI not in topmost frame>, msg=0x4e, wp=0x3e8, lp=0x33e4a0, result=0x33e34c, arg=0x7ed7d990) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:457] in user32 (0x0033e2a8) 34 0x7eb842f1 WINPROC_call_window+0xd1(hwnd=<register ESI not in topmost frame>, msg=0x4e, wParam=0x3e8, lParam=0x33e4a0, result=0x33e34c, unicode=0x1, mapping=0x1) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2207] in user32 (0x0033e2e8) 35 0x7eb458ca call_window_proc+0xca(hwnd=<register ESI not in topmost frame>, msg=0x4e, wparam=0x3e8, lparam=0x33e4a0, unicode=0x1, same_thread=0x1, mapping=0x1) [/home/sedwards/source/wine-git/dlls/user32/message.c:1639] in user32 (0x0033e358) 36 0x7eb48862 send_message+0x222(info=<register EDI not in topmost frame>, res_ptr=0x33e3f4, unicode=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/message.c:2463] in user32 (0x0033e3b8) 37 0x7eb48cda SendMessageW+0x4a(hwnd=0x10026, msg=0x4e, wparam=0x3e8, lparam=0x33e4a0) [/home/sedwards/source/wine-git/dlls/user32/message.c:2586] in user32 (0x0033e3f8) 38 0x7ea2b89b notify_hdr+0x6b(infoPtr=<register EDI not in topmost frame>, code=0xfffffffd, pnmh=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/comctl32/listview.c:737] in comctl32 (0x0033e428) 39 0x7ea3364f notify_click+0x16f(infoPtr=0x1337e8, code=0xfffffffd, lvht=0x33e578) [/home/sedwards/source/wine-git/dlls/comctl32/listview.c:806] in comctl32 (0x0033e4d8) 40 0x7ea33955 LISTVIEW_LButtonDblClk+0xa5(infoPtr=<register EDI not in topmost frame>, wKey=<is not available>, x=0x28, y=0x15) [/home/sedwards/source/wine-git/dlls/comctl32/listview.c:8557] in comctl32 (0x0033e598) 41 0x7ea3ecbe LISTVIEW_WindowProc+0x3de(hwnd=0x1002a, uMsg=0x203, wParam=0x1, lParam=0x15) [/home/sedwards/source/wine-git/dlls/comctl32/listview.c:9926] in comctl32 (0x0033ee98) 42 0x7eb7d8da WINPROC_wrapper+0x1a() in user32 (0x0033eec8) 43 0x7eb7dfce call_window_proc+0x6e(hwnd=<register EDI not in topmost frame>, msg=0x203, wp=0x1, lp=0x150028, result=0x33ef78, arg=0x7ea3e8e0) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:457] in user32 (0x0033ef08) 44 0x7eb842f1 WINPROC_call_window+0xd1(hwnd=<register ESI not in topmost frame>, msg=0x203, wParam=0x1, lParam=0x150028, result=0x33ef78, unicode=0x1, mapping=0x4) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2207] in user32 (0x0033ef48) 45 0x7eb45186 DispatchMessageW+0x96(msg=<register EDI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/message.c:3125] in user32 (0x0033ef88) 46 0x7ed7f177 Control_RunDLLW+0x3f7(hWnd=0x10020, hInst=0x0, cmd=0x1326f0, nCmdShow=0x5) [/home/sedwards/source/wine-git/dlls/shell32/control.c:620] in shell32 (0x0033fcc8) 47 0x7ed7f76d Control_RunDLLA+0xfd(hWnd=0x10020, hInst=0x0, cmd=0x7ee7eb43, nCmdShow=0x5) [/home/sedwards/source/wine-git/dlls/shell32/control.c:825] in shell32 (0x0033fcf8) 48 0x7ee7e5ea launch+0x3a(what=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/programs/control/control.c:31] in control (0x0033fd18) 49 0x7ee7e665 WinMain+0x65(hInst=0x7ee70000, hPrev=0x0, lpszCmdLine=0x110860, nCmdShow=0x1) [/home/sedwards/source/wine-git/programs/control/control.c:70] in control (0x0033fe58) 50 0x7ee7e963 main+0xa3() [/home/sedwards/source/wine-git/dlls/winecrt0/exe_main.c:48] in control (0x0033fed8) 51 0x7ee7e88b __wine_spec_exe_entry+0x5b(peb=0x7ffdf000) [/home/sedwards/source/wine-git/dlls/winecrt0/exe_entry.c:36] in control (0x0033ff08) 52 0x7b877ef7 start_process+0xc7(arg=0x0) [/home/sedwards/source/wine-git/dlls/kernel32/process.c:904] in kernel32 (0x0033ffe8)
-- Steven Edwards
"There is one thing stronger than all the armies in the world, and that is an idea whose time has come." - Victor Hugo
I think the proper fix is for appwiz.cpl to process the CPL_STOP and CPL_EXIT messages (see http://msdn.microsoft.com/en-us/library/aa454656.aspx)
Vincent Povirk
On Thu, Aug 21, 2008 at 9:55 PM, Vincent Povirk madewokherd+8cd9@gmail.com wrote:
Commenting out FreeLibrary(applet->hModule); in Control_UnloadApplet avoids the crash. The problem is that the applet's dialog still exists when FreeLibrary is called. Since its dialog procedure was in the freed library, the program crashes when that dialog gets a message.
I don't know what the proper fix is.
Vincent Povirk
On Thu, Aug 21, 2008 at 9:26 PM, Steven Edwards winehacker@gmail.com wrote:
On Thu, Aug 21, 2008 at 9:00 PM, Vincent Povirk madewokherd+8cd9@gmail.com wrote:
Why doesn't the WM_DESTROY case handle this properly? At first glance, it appears to have code for stopping the running applets and quitting from the main loop.
Calling ExitProcess from WM_CLOSE is anything but graceful.
I am not sure what the right answer is as I've never really tried to fix this type of problem before, WM_DESTROY does not seem to do something right, as even making WM_CLOSE fall through to it produces the same crash. I spent some time trying to debug the problem but got no where so I started just blindly adding PostQuitMessages and ExitProcess calls around the areas in the backtrace until I found something that got rid of the crash. Its easy to replicate, just run control, open the appwiz.cpl and then close the control panel window with the cpl applet still open.
Here is the backtrace
wine: Unhandled page fault on execute access to 0x7e50da00 at address 0x7e50da00 (thread 0009), starting debugger... Unhandled exception: page fault on execute access to 0x7e50da00 in 32-bit code (0x7e50da00). Register dump: CS:0023 SS:002b DS:002b ES:002b FS:0063 GS:006b EIP:7e50da00 ESP:0033b57c EBP:0033b5a8 EFLAGS:00010206( - 00 - RIP1) EAX:7e50da00 EBX:7eba0574 ECX:00000000 EDX:7e50da00 ESI:00000000 EDI:0001003a Stack dump: 0x0033b57c: 7eb7d8da 0001003a 00000018 00000000 0x0033b58c: 00000000 7ebbfe80 7eba0574 0033b5a8 0x0033b59c: 7eba0574 00000000 0001003a 0033b5e8 0x0033b5ac: 7eb7f738 7e50da00 0001003a 00000018 0x0033b5bc: 00000000 00000000 00000000 0033b5d8 0x0033b5cc: 7eb6f120 7ebbfe80 7eba0574 7eb7f6db Backtrace: =>1 0x7e50da00 (0x0033b5a8) 2 0x7eb7f738 call_dialog_proc+0x68(hwnd=<register EDI not in topmost frame>, msg=0x18, wp=0x0, lp=0x0, result=0x33b618, arg=0x7e50da00) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:479] in user32 (0x0033b5e8) 3 0x7eb82f5a WINPROC_CallDlgProcW+0x5a(func=0xffff0026, hwnd=0x1003a, msg=0x18, wParam=<register EDI not in topmost frame>, lParam=0x0) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2394] in user32 (0x0033b628) 4 0x7eb0a2d5 DefDlgProcW+0x85(hwnd=<register ESI not in topmost frame>, msg=0x18, wParam=0x0, lParam=0x0) [/home/sedwards/source/wine-git/dlls/user32/defdlg.c:488] in user32 (0x0033b658) 5 0x7eb7d8da WINPROC_wrapper+0x1a() in user32 (0x0033b688) 6 0x7eb7dfce call_window_proc+0x6e(hwnd=<register EDI not in topmost frame>, msg=0x18, wp=0x0, lp=0x0, result=0x33b76c, arg=0x7eb0a250) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:457] in user32 (0x0033b6c8) 7 0x7eb842f1 WINPROC_call_window+0xd1(hwnd=<register ESI not in topmost frame>, msg=0x18, wParam=0x0, lParam=0x0, result=0x33b76c, unicode=0x1, mapping=0x1) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2207] in user32 (0x0033b708) 8 0x7eb458ca call_window_proc+0xca(hwnd=<register ESI not in topmost frame>, msg=0x18, wparam=0x0, lparam=0x0, unicode=0x1, same_thread=0x1, mapping=0x1) [/home/sedwards/source/wine-git/dlls/user32/message.c:1639] in user32 (0x0033b778) 9 0x7eb48862 send_message+0x222(info=<register EDI not in topmost frame>, res_ptr=0x33b814, unicode=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/message.c:2463] in user32 (0x0033b7d8) 10 0x7eb48cda SendMessageW+0x4a(hwnd=0x1003a, msg=0x18, wparam=0x0, lparam=0x0) [/home/sedwards/source/wine-git/dlls/user32/message.c:2586] in user32 (0x0033b818) 11 0x7eb7cd06 show_window+0x4d6(hwnd=0x1003a, cmd=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/winpos.c:1046] in user32 (0x0033b888) 12 0x7eb7ce4b ShowWindow+0x3b(hwnd=<register ESI not in topmost frame>, cmd=0x0) [/home/sedwards/source/wine-git/dlls/user32/winpos.c:1154] in user32 (0x0033b8a8) 13 0x7eb724fc DestroyWindow+0x1bc(hwnd=0x1003a) [/home/sedwards/source/wine-git/dlls/user32/win.c:1502] in user32 (0x0033b8e8) 14 0x7ea4e49b PROPSHEET_CleanUp+0xcb(hwndDlg=<is not available>) [/home/sedwards/source/wine-git/dlls/comctl32/propsheet.c:2720] in comctl32 (0x0033b918) 15 0x7ea51ef5 PROPSHEET_DialogProc+0x595(hwnd=0x1002e, uMsg=<register ESI not in topmost frame>, wParam=0x0, lParam=0x0) [/home/sedwards/source/wine-git/dlls/comctl32/propsheet.c:3534] in comctl32 (0x0033bc48) 16 0x7eb7d8da WINPROC_wrapper+0x1a() in user32 (0x0033bc78) 17 0x7eb7f738 call_dialog_proc+0x68(hwnd=<register EDI not in topmost frame>, msg=0x2, wp=0x0, lp=0x0, result=0x33bce8, arg=0x7ea51960) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:479] in user32 (0x0033bcb8) 18 0x7eb82f5a WINPROC_CallDlgProcW+0x5a(func=0xffff0025, hwnd=0x1002e, msg=0x2, wParam=<register EDI not in topmost frame>, lParam=0x0) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2394] in user32 (0x0033bcf8) 19 0x7eb0a2d5 DefDlgProcW+0x85(hwnd=<register ESI not in topmost frame>, msg=0x2, wParam=0x0, lParam=0x0) [/home/sedwards/source/wine-git/dlls/user32/defdlg.c:488] in user32 (0x0033bd28) 20 0x7eb7d8da WINPROC_wrapper+0x1a() in user32 (0x0033bd58) 21 0x7eb7dfce call_window_proc+0x6e(hwnd=<register EDI not in topmost frame>, msg=0x2, wp=0x0, lp=0x0, result=0x33be3c, arg=0x7eb0a250) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:457] in user32 (0x0033bd98) 22 0x7eb842f1 WINPROC_call_window+0xd1(hwnd=<register ESI not in topmost frame>, msg=0x2, wParam=0x0, lParam=0x0, result=0x33be3c, unicode=0x1, mapping=0x1002e) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2207] in user32 (0x0033bdd8) 23 0x7eb458ca call_window_proc+0xca(hwnd=<register ESI not in topmost frame>, msg=0x2, wparam=0x0, lparam=0x0, unicode=0x1, same_thread=0x1, mapping=0x1002e) [/home/sedwards/source/wine-git/dlls/user32/message.c:1639] in user32 (0x0033be48) 24 0x7eb48862 send_message+0x222(info=<register EDI not in topmost frame>, res_ptr=0x33bee4, unicode=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/message.c:2463] in user32 (0x0033bea8) 25 0x7eb48cda SendMessageW+0x4a(hwnd=0x1002e, msg=0x2, wparam=0x0, lparam=0x0) [/home/sedwards/source/wine-git/dlls/user32/message.c:2586] in user32 (0x0033bee8) 26 0x7eb71186 WIN_SendDestroyMsg+0x66(hwnd=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/win.c:1436] in user32 (0x0033bf48) 27 0x7eb72521 DestroyWindow+0x1e1(hwnd=0x1002e) [/home/sedwards/source/wine-git/dlls/user32/win.c:1540] in user32 (0x0033bf88) 28 0x7ea4f8a0 PROPSHEET_PropertySheet+0x2c0(psInfo=0x1381c0, unicode=<is not available>) [/home/sedwards/source/wine-git/dlls/comctl32/propsheet.c:2803] in comctl32 (0x0033bfe8) 29 0x7ea500cf PropertySheetW+0x1cf(lppsh=0x33d080) [/home/sedwards/source/wine-git/dlls/comctl32/propsheet.c:2900] in comctl32 (0x0033c058) 30 0x7e50c930 (0x0033d0f8) 31 0x7ed7e3cd Control_WndProc+0xa3d(hWnd=0x10026, wMsg=0x4e, lParam1=0x3e8, lParam2=0x33e4a0) [/home/sedwards/source/wine-git/dlls/shell32/control.c:501] in shell32 (0x0033e238) 32 0x7eb7d8da WINPROC_wrapper+0x1a() in user32 (0x0033e268) 33 0x7eb7dfce call_window_proc+0x6e(hwnd=<register EDI not in topmost frame>, msg=0x4e, wp=0x3e8, lp=0x33e4a0, result=0x33e34c, arg=0x7ed7d990) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:457] in user32 (0x0033e2a8) 34 0x7eb842f1 WINPROC_call_window+0xd1(hwnd=<register ESI not in topmost frame>, msg=0x4e, wParam=0x3e8, lParam=0x33e4a0, result=0x33e34c, unicode=0x1, mapping=0x1) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2207] in user32 (0x0033e2e8) 35 0x7eb458ca call_window_proc+0xca(hwnd=<register ESI not in topmost frame>, msg=0x4e, wparam=0x3e8, lparam=0x33e4a0, unicode=0x1, same_thread=0x1, mapping=0x1) [/home/sedwards/source/wine-git/dlls/user32/message.c:1639] in user32 (0x0033e358) 36 0x7eb48862 send_message+0x222(info=<register EDI not in topmost frame>, res_ptr=0x33e3f4, unicode=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/message.c:2463] in user32 (0x0033e3b8) 37 0x7eb48cda SendMessageW+0x4a(hwnd=0x10026, msg=0x4e, wparam=0x3e8, lparam=0x33e4a0) [/home/sedwards/source/wine-git/dlls/user32/message.c:2586] in user32 (0x0033e3f8) 38 0x7ea2b89b notify_hdr+0x6b(infoPtr=<register EDI not in topmost frame>, code=0xfffffffd, pnmh=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/comctl32/listview.c:737] in comctl32 (0x0033e428) 39 0x7ea3364f notify_click+0x16f(infoPtr=0x1337e8, code=0xfffffffd, lvht=0x33e578) [/home/sedwards/source/wine-git/dlls/comctl32/listview.c:806] in comctl32 (0x0033e4d8) 40 0x7ea33955 LISTVIEW_LButtonDblClk+0xa5(infoPtr=<register EDI not in topmost frame>, wKey=<is not available>, x=0x28, y=0x15) [/home/sedwards/source/wine-git/dlls/comctl32/listview.c:8557] in comctl32 (0x0033e598) 41 0x7ea3ecbe LISTVIEW_WindowProc+0x3de(hwnd=0x1002a, uMsg=0x203, wParam=0x1, lParam=0x15) [/home/sedwards/source/wine-git/dlls/comctl32/listview.c:9926] in comctl32 (0x0033ee98) 42 0x7eb7d8da WINPROC_wrapper+0x1a() in user32 (0x0033eec8) 43 0x7eb7dfce call_window_proc+0x6e(hwnd=<register EDI not in topmost frame>, msg=0x203, wp=0x1, lp=0x150028, result=0x33ef78, arg=0x7ea3e8e0) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:457] in user32 (0x0033ef08) 44 0x7eb842f1 WINPROC_call_window+0xd1(hwnd=<register ESI not in topmost frame>, msg=0x203, wParam=0x1, lParam=0x150028, result=0x33ef78, unicode=0x1, mapping=0x4) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2207] in user32 (0x0033ef48) 45 0x7eb45186 DispatchMessageW+0x96(msg=<register EDI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/message.c:3125] in user32 (0x0033ef88) 46 0x7ed7f177 Control_RunDLLW+0x3f7(hWnd=0x10020, hInst=0x0, cmd=0x1326f0, nCmdShow=0x5) [/home/sedwards/source/wine-git/dlls/shell32/control.c:620] in shell32 (0x0033fcc8) 47 0x7ed7f76d Control_RunDLLA+0xfd(hWnd=0x10020, hInst=0x0, cmd=0x7ee7eb43, nCmdShow=0x5) [/home/sedwards/source/wine-git/dlls/shell32/control.c:825] in shell32 (0x0033fcf8) 48 0x7ee7e5ea launch+0x3a(what=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/programs/control/control.c:31] in control (0x0033fd18) 49 0x7ee7e665 WinMain+0x65(hInst=0x7ee70000, hPrev=0x0, lpszCmdLine=0x110860, nCmdShow=0x1) [/home/sedwards/source/wine-git/programs/control/control.c:70] in control (0x0033fe58) 50 0x7ee7e963 main+0xa3() [/home/sedwards/source/wine-git/dlls/winecrt0/exe_main.c:48] in control (0x0033fed8) 51 0x7ee7e88b __wine_spec_exe_entry+0x5b(peb=0x7ffdf000) [/home/sedwards/source/wine-git/dlls/winecrt0/exe_entry.c:36] in control (0x0033ff08) 52 0x7b877ef7 start_process+0xc7(arg=0x0) [/home/sedwards/source/wine-git/dlls/kernel32/process.c:904] in kernel32 (0x0033ffe8)
-- Steven Edwards
"There is one thing stronger than all the armies in the world, and that is an idea whose time has come." - Victor Hugo
On Thu, Aug 21, 2008 at 11:08 PM, Vincent Povirk madewokherd+8cd9@gmail.com wrote:
I think the proper fix is for appwiz.cpl to process the CPL_STOP and CPL_EXIT messages (see http://msdn.microsoft.com/en-us/library/aa454656.aspx)
I still think there could be a bug as I have IE installed and I assume the internet options dialog has the CPL_EXIT case and if I exit the control panel with that applet loaded I get the following output
err:seh:setup_exception_record stack overflow 1176 bytes in thread 0017 eip 7bc78c4a esp 00240e98 stack 0x240000-0x241000-0x340000
I'm going to look tomorrow at adding the CPL_EXIT and CPL_STOP messages to appwiz so we can get a better idea of what exactly is going on.
Here is a backtrace from winedbg exiting the control panel with the internet options dialog
=>1 0x7bc65f95 check_atl_thunk+0x65(rec=<is not available>, context=0x33bff4) [/home/sedwards/source/wine-git/dlls/ntdll/signal_i386.c:1030] in ntdll (0x0033bfc4) 2 0x7bc66114 raise_segv_exception+0xa4(rec=<register ESI not in topmost frame>, context=<register EDI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/ntdll/signal_i386.c:1210] in ntdll (0x0033bfe4) 3 0xdeadbabe (0x0033c344) 4 0x7eb74738 call_dialog_proc+0x68(hwnd=<register EDI not in topmost frame>, msg=0x18, wp=0x0, lp=0x0, result=0x33c3b4, arg=0x11a0431) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:479] in user32 (0x0033c384) 5 0x7eb77f5a WINPROC_CallDlgProcW+0x5a(func=0xffff0027, hwnd=0x1003e, msg=0x18, wParam=<register EDI not in topmost frame>, lParam=0x0) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2394] in user32 (0x0033c3c4) 6 0x7eaff2d5 DefDlgProcW+0x85(hwnd=<register ESI not in topmost frame>, msg=0x18, wParam=0x0, lParam=0x0) [/home/sedwards/source/wine-git/dlls/user32/defdlg.c:488] in user32 (0x0033c3f4) 7 0x7eb728da WINPROC_wrapper+0x1a() in user32 (0x0033c424) 8 0x7eb72fce call_window_proc+0x6e(hwnd=<register EDI not in topmost frame>, msg=0x18, wp=0x0, lp=0x0, result=0x33c508, arg=0x7eaff250) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:457] in user32 (0x0033c464) 9 0x7eb792f1 WINPROC_call_window+0xd1(hwnd=<register ESI not in topmost frame>, msg=0x18, wParam=0x0, lParam=0x0, result=0x33c508, unicode=0x1, mapping=0x1) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2207] in user32 (0x0033c4a4) 10 0x7eb3a8ca call_window_proc+0xca(hwnd=<register ESI not in topmost frame>, msg=0x18, wparam=0x0, lparam=0x0, unicode=0x1, same_thread=0x1, mapping=0x1) [/home/sedwards/source/wine-git/dlls/user32/message.c:1639] in user32 (0x0033c514) 11 0x7eb3d862 send_message+0x222(info=<register EDI not in topmost frame>, res_ptr=0x33c5b0, unicode=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/message.c:2463] in user32 (0x0033c574) 12 0x7eb3dcda SendMessageW+0x4a(hwnd=0x1003e, msg=0x18, wparam=0x0, lparam=0x0) [/home/sedwards/source/wine-git/dlls/user32/message.c:2586] in user32 (0x0033c5b4) 13 0x7eb71d06 show_window+0x4d6(hwnd=0x1003e, cmd=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/winpos.c:1046] in user32 (0x0033c624) 14 0x7eb71e4b ShowWindow+0x3b(hwnd=<register ESI not in topmost frame>, cmd=0x0) [/home/sedwards/source/wine-git/dlls/user32/winpos.c:1154] in user32 (0x0033c644) 15 0x7eb674fc DestroyWindow+0x1bc(hwnd=0x1003e) [/home/sedwards/source/wine-git/dlls/user32/win.c:1502] in user32 (0x0033c684) 16 0x7ea4349b PROPSHEET_CleanUp+0xcb(hwndDlg=<is not available>) [/home/sedwards/source/wine-git/dlls/comctl32/propsheet.c:2720] in comctl32 (0x0033c6b4) 17 0x7ea46ef5 PROPSHEET_DialogProc+0x595(hwnd=0x10032, uMsg=<register ESI not in topmost frame>, wParam=0x0, lParam=0x0) [/home/sedwards/source/wine-git/dlls/comctl32/propsheet.c:3534] in comctl32 (0x0033c9e4) 18 0x7eb728da WINPROC_wrapper+0x1a() in user32 (0x0033ca14) 19 0x7eb74738 call_dialog_proc+0x68(hwnd=<register EDI not in topmost frame>, msg=0x2, wp=0x0, lp=0x0, result=0x33ca84, arg=0x7ea46960) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:479] in user32 (0x0033ca54) 20 0x7eb77f5a WINPROC_CallDlgProcW+0x5a(func=0xffff0026, hwnd=0x10032, msg=0x2, wParam=<register EDI not in topmost frame>, lParam=0x0) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2394] in user32 (0x0033ca94) 21 0x7eaff2d5 DefDlgProcW+0x85(hwnd=<register ESI not in topmost frame>, msg=0x2, wParam=0x0, lParam=0x0) [/home/sedwards/source/wine-git/dlls/user32/defdlg.c:488] in user32 (0x0033cac4) 22 0x7eb728da WINPROC_wrapper+0x1a() in user32 (0x0033caf4) 23 0x7eb72fce call_window_proc+0x6e(hwnd=<register EDI not in topmost frame>, msg=0x2, wp=0x0, lp=0x0, result=0x33cbd8, arg=0x7eaff250) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:457] in user32 (0x0033cb34) 24 0x7eb792f1 WINPROC_call_window+0xd1(hwnd=<register ESI not in topmost frame>, msg=0x2, wParam=0x0, lParam=0x0, result=0x33cbd8, unicode=0x1, mapping=0x10032) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2207] in user32 (0x0033cb74) 25 0x7eb3a8ca call_window_proc+0xca(hwnd=<register ESI not in topmost frame>, msg=0x2, wparam=0x0, lparam=0x0, unicode=0x1, same_thread=0x1, mapping=0x10032) [/home/sedwards/source/wine-git/dlls/user32/message.c:1639] in user32 (0x0033cbe4) 26 0x7eb3d862 send_message+0x222(info=<register EDI not in topmost frame>, res_ptr=0x33cc80, unicode=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/message.c:2463] in user32 (0x0033cc44) 27 0x7eb3dcda SendMessageW+0x4a(hwnd=0x10032, msg=0x2, wparam=0x0, lparam=0x0) [/home/sedwards/source/wine-git/dlls/user32/message.c:2586] in user32 (0x0033cc84) 28 0x7eb66186 WIN_SendDestroyMsg+0x66(hwnd=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/win.c:1436] in user32 (0x0033cce4) 29 0x7eb67521 DestroyWindow+0x1e1(hwnd=0x10032) [/home/sedwards/source/wine-git/dlls/user32/win.c:1540] in user32 (0x0033cd24) 30 0x7ea448a0 PROPSHEET_PropertySheet+0x2c0(psInfo=0x141718, unicode=<is not available>) [/home/sedwards/source/wine-git/dlls/comctl32/propsheet.c:2803] in comctl32 (0x0033cd84) 31 0x7ea450cf PropertySheetW+0x1cf(lppsh=0x33cea4) [/home/sedwards/source/wine-git/dlls/comctl32/propsheet.c:2900] in comctl32 (0x0033cdf4) 32 0x011aac70 (0x0033ce2c) 33 0x011a32bd (0x0033cedc) 34 0x011a06b0 (0x0033d0f8) 35 0x7ed733cd Control_WndProc+0xa3d(hWnd=0x10026, wMsg=0x4e, lParam1=0x3e8, lParam2=0x33e4a0) [/home/sedwards/source/wine-git/dlls/shell32/control.c:501] in shell32 (0x0033e238) 36 0x7eb728da WINPROC_wrapper+0x1a() in user32 (0x0033e268) 37 0x7eb72fce call_window_proc+0x6e(hwnd=<register EDI not in topmost frame>, msg=0x4e, wp=0x3e8, lp=0x33e4a0, result=0x33e34c, arg=0x7ed72990) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:457] in user32 (0x0033e2a8) 38 0x7eb792f1 WINPROC_call_window+0xd1(hwnd=<register ESI not in topmost frame>, msg=0x4e, wParam=0x3e8, lParam=0x33e4a0, result=0x33e34c, unicode=0x1, mapping=0x1) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2207] in user32 (0x0033e2e8) 39 0x7eb3a8ca call_window_proc+0xca(hwnd=<register ESI not in topmost frame>, msg=0x4e, wparam=0x3e8, lparam=0x33e4a0, unicode=0x1, same_thread=0x1, mapping=0x1) [/home/sedwards/source/wine-git/dlls/user32/message.c:1639] in user32 (0x0033e358) 40 0x7eb3d862 send_message+0x222(info=<register EDI not in topmost frame>, res_ptr=0x33e3f4, unicode=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/message.c:2463] in user32 (0x0033e3b8) 41 0x7eb3dcda SendMessageW+0x4a(hwnd=0x10026, msg=0x4e, wparam=0x3e8, lparam=0x33e4a0) [/home/sedwards/source/wine-git/dlls/user32/message.c:2586] in user32 (0x0033e3f8) 42 0x7ea2089b notify_hdr+0x6b(infoPtr=<register EDI not in topmost frame>, code=0xfffffffd, pnmh=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/comctl32/listview.c:737] in comctl32 (0x0033e428) 43 0x7ea2864f notify_click+0x16f(infoPtr=0x133560, code=0xfffffffd, lvht=0x33e578) [/home/sedwards/source/wine-git/dlls/comctl32/listview.c:806] in comctl32 (0x0033e4d8) 44 0x7ea28955 LISTVIEW_LButtonDblClk+0xa5(infoPtr=<register EDI not in topmost frame>, wKey=<is not available>, x=0x66, y=0x1f) [/home/sedwards/source/wine-git/dlls/comctl32/listview.c:8557] in comctl32 (0x0033e598) 45 0x7ea33cbe LISTVIEW_WindowProc+0x3de(hwnd=0x1002a, uMsg=0x203, wParam=0x1, lParam=0x1f) [/home/sedwards/source/wine-git/dlls/comctl32/listview.c:9926] in comctl32 (0x0033ee98) 46 0x7eb728da WINPROC_wrapper+0x1a() in user32 (0x0033eec8) 47 0x7eb72fce call_window_proc+0x6e(hwnd=<register EDI not in topmost frame>, msg=0x203, wp=0x1, lp=0x1f0066, result=0x33ef78, arg=0x7ea338e0) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:457] in user32 (0x0033ef08) 48 0x7eb792f1 WINPROC_call_window+0xd1(hwnd=<register ESI not in topmost frame>, msg=0x203, wParam=0x1, lParam=0x1f0066, result=0x33ef78, unicode=0x1, mapping=0x4) [/home/sedwards/source/wine-git/dlls/user32/winproc.c:2207] in user32 (0x0033ef48) 49 0x7eb3a186 DispatchMessageW+0x96(msg=<register EDI not in topmost frame>) [/home/sedwards/source/wine-git/dlls/user32/message.c:3125] in user32 (0x0033ef88) 50 0x7ed74177 Control_RunDLLW+0x3f7(hWnd=0x10020, hInst=0x0, cmd=0x132408, nCmdShow=0x5) [/home/sedwards/source/wine-git/dlls/shell32/control.c:620] in shell32 (0x0033fcc8) 51 0x7ed7476d Control_RunDLLA+0xfd(hWnd=0x10020, hInst=0x0, cmd=0x7ee73b43, nCmdShow=0x5) [/home/sedwards/source/wine-git/dlls/shell32/control.c:825] in shell32 (0x0033fcf8) 52 0x7ee735ea launch+0x3a(what=<register ESI not in topmost frame>) [/home/sedwards/source/wine-git/programs/control/control.c:31] in control (0x0033fd18) 53 0x7ee73665 WinMain+0x65(hInst=0x7ee70000, hPrev=0x0, lpszCmdLine=0x110b10, nCmdShow=0x1) [/home/sedwards/source/wine-git/programs/control/control.c:70] in control (0x0033fe58) 54 0x7ee73963 main+0xa3() [/home/sedwards/source/wine-git/dlls/winecrt0/exe_main.c:48] in control (0x0033fed8) 55 0x7ee7388b __wine_spec_exe_entry+0x5b(peb=0x7ffdf000) [/home/sedwards/source/wine-git/dlls/winecrt0/exe_entry.c:36] in control (0x0033ff08) 56 0x7b877ef7 start_process+0xc7(arg=0x0) [/home/sedwards/source/wine-git/dlls/kernel32/process.c:904] in kernel32 (0x0033ffe8)
Vincent Povirk wrote:
Why doesn't the WM_DESTROY case handle this properly? At first glance, it appears to have code for stopping the running applets and quitting from the main loop.
WM_CLOSE is different than WM_DESTROY. This is a missing case that needs to be handled whenever the Windows Manger receives this message. Good catch, Steven.
James McKenzie
WM_CLOSE is already handled by the default window procedure, DefWindowProcW, which calls DestroyWindow. It's only necessary to override the default for WM_CLOSE if you want to prevent the window from being destroyed.
Vincent Povirk
On Thu, Aug 21, 2008 at 10:44 PM, James McKenzie jjmckenzie51@earthlink.net wrote:
Vincent Povirk wrote:
Why doesn't the WM_DESTROY case handle this properly? At first glance, it appears to have code for stopping the running applets and quitting from the main loop.
WM_CLOSE is different than WM_DESTROY. This is a missing case that needs to be handled whenever the Windows Manger receives this message. Good catch, Steven.
James McKenzie