http://bugs.winehq.org/show_bug.cgi?id=37064
Bug ID: 37064 Summary: Ultima IX sometimes crashes on exit Product: Wine Version: 1.7.23 Hardware: x86 OS: Linux Status: UNCONFIRMED Severity: minor Priority: P2 Component: -unknown Assignee: wine-bugs@winehq.org Reporter: cthielen@gmail.com
Created attachment 49253 --> http://bugs.winehq.org/attachment.cgi?id=49253 Wine backtrace of crash
The crash is only after the game has completely exited and does not always happen.
Before the crash, there's also some curious output on the terminal, in particular, a call to wined3d_unregister_window that wined3d was not tracking:
fixme:d3d:check_fbo_compat Format WINED3DFMT_R16G16_UNORM with rendertarget flag is not supported as FBO color attachment, and no fallback specified. fixme:d3d:check_fbo_compat Format WINED3DFMT_R16G16B16A16_UNORM with rendertarget flag is not supported as FBO color attachment, and no fallback specified. fixme:win:EnumDisplayDevicesW ((null),0,0x32e8c8,0x00000000), stub! fixme:d3d:check_fbo_compat Format WINED3DFMT_R16G16_UNORM with rendertarget flag is not supported as FBO color attachment, and no fallback specified. fixme:d3d:check_fbo_compat Format WINED3DFMT_R16G16B16A16_UNORM with rendertarget flag is not supported as FBO color attachment, and no fallback specified. fixme:win:EnumDisplayDevicesW ((null),0,0x32e6a8,0x00000000), stub! err:d3d:wined3d_unregister_window Window 0x10058 is not registered with wined3d. wine: Unhandled page fault on read access to 0x0000003c at address 0x5d5c66 (thread 0009), starting debugger... fixme:dbghelp_msc:pe_load_debug_directory This guy has FPO information fixme:ole:RemUnknown_QueryInterface No interface for iid {00000019-0000-0000-c000-000000000046}
http://bugs.winehq.org/show_bug.cgi?id=37064
Béla Gyebrószki gyebro69@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |regression Status|UNCONFIRMED |NEW CC| |gyebro69@gmail.com, | |piotr.caban@gmail.com Component|-unknown |user32 Ever confirmed|0 |1 Regression SHA1| |55ff0661038da271d92b5951a62 | |f66e898b8cba2
--- Comment #1 from Béla Gyebrószki gyebro69@gmail.com --- I can reproduce the problem with the GOG.com version of the game. The game often (but not always) crashes on exit. This made regression testing a bit more difficult, but finally I found the commit which resulted the crash:
55ff0661038da271d92b5951a62f66e898b8cba2 is the first bad commit commit 55ff0661038da271d92b5951a62f66e898b8cba2 Author: Piotr Caban piotr@codeweavers.com Date: Thu Apr 10 14:50:33 2014 +0200
user32: Don't fail on windows without menu bar in DrawMenuBar.
:040000 040000 89a6c3c9557c8e2502812e03c65700c02666a469 654a0ab694344aa53128cae8fbef9ad8d4c90465 M dlls
wine-1.7.23-90-gbdeb761 Fedora 20 XFCE 4.10
https://bugs.winehq.org/show_bug.cgi?id=37064
--- Comment #2 from Piotr Caban piotr.caban@gmail.com --- Could you please attach a seh,tid,relay log?
https://bugs.winehq.org/show_bug.cgi?id=37064
--- Comment #3 from Béla Gyebrószki gyebro69@gmail.com --- Created attachment 49381 --> https://bugs.winehq.org/attachment.cgi?id=49381 +relay,+seh,+tid log (uncompressed 83 MB)
https://bugs.winehq.org/show_bug.cgi?id=37064
--- Comment #4 from Piotr Caban piotr.caban@gmail.com --- If I'm not missing something DrawMenuBar is behaving correcly in this case.
Some interesting parts of the log (only some lines are pasted here): 0009:Call user32.DestroyWindow(0001004e) ret=005d5d67 0009:Call user32.DrawMenuBar(0001004e) ret=10003da0 0009:Ret user32.DrawMenuBar() retval=00000001 ret=10003da0 0009:Call user32.PostQuitMessage(00000000) ret=0049ea43 0009:Ret user32.PostQuitMessage() retval=00000000 ret=0049ea43 0009:Ret user32.DestroyWindow() retval=00000001 ret=005d5d67 0009:Call user32.PeekMessageA(0032f96c,00000000,00000000,00000000,00000001) ret=005d6fc0 0009:Ret user32.PeekMessageA() retval=00000000 ret=005d6fc0 0009:trace:seh:raise_exception code=c0000005 flags=0 addr=0x5d5c66 ip=005d5c66 tid=0009
After PostQuitMessage I don't see any calls that are affecting message queue. I don't understand why PeekMessage is not returning WM_QUIT message here.
https://bugs.winehq.org/show_bug.cgi?id=37064
--- Comment #5 from Piotr Caban piotr.caban@gmail.com --- Because of the DrawMenuBar change the application executes different code path. I can reproduce the bug with following test:
HWND win = CreateWindowEx(0, L"static", L"static", WS_VISIBLE, 0, 0, 100, 100, 0, 0, 0, 0);
RECT rect = {0, 0, 100, 100}; ClipCursor(&rect); DestroyWindow(win); PostQuitMessage(0); ClipCursor(NULL);
MSG msg; printf("--> %x\n", PeekMessage(&msg, 0, 0, 0, 0)); printf("%x\n", msg.message);
It's only reproducible when winex11.drv is used. For some reason sometimes WM_QUIT message is getting removed (it's probably a race).
https://bugs.winehq.org/show_bug.cgi?id=37064
Piotr Caban piotr.caban@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Fixed by SHA1| |03f645a76bf697ead28df5de665 | |cb351b2d996f9 Status|NEW |RESOLVED Resolution|--- |FIXED
--- Comment #6 from Piotr Caban piotr.caban@gmail.com --- It works for me now. Marking as fixed.
https://bugs.winehq.org/show_bug.cgi?id=37064
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #7 from Alexandre Julliard julliard@winehq.org --- Closing bugs fixed in 1.7.37.