https://bugs.winehq.org/show_bug.cgi?id=49649
Bug ID: 49649 Summary: Regression: X11 crash on resolution change Product: Wine Version: 4.6 Hardware: x86 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: winex11.drv Assignee: wine-bugs@winehq.org Reporter: vv221+winehq@dotslashplay.it Distribution: ---
Created attachment 67858 --> https://bugs.winehq.org/attachment.cgi?id=67858 x-error-of-failed-request.log
Since commit 0cb79db12ac7c48477518dcff269ccc5d6b745e0, resolution change in some games lead to a X11 crash similar to the one pasted in the attachment "x-error-of-failed-request.log".
I assigned this bug to WINE 4.6 as this is the first version triggering it, but it is still there with current master (5.14). A revert of the faulty commit still applies cleanly on top of WINE 5.14.
The regression test has been done using Age of Empires to trigger the crash, as it happens reliably when trying to change the game resolution (640x480, 800x600, 1024x768) through the game options.
If the change is done without crashing, using a patched WINE build, the game will start in the new resolution next time and work fine with it even when going back to an unpatched WINE build. But trying to change the resolution again in unpatched WINE, including to go back to the previous resolution in use, would trigger the crash again.
I think this might be the same bug that got experienced in #47677, I’m going to run some tests with Age of Empires 2 to get a confirmation.
https://bugs.winehq.org/show_bug.cgi?id=49649
vv221 vv221+winehq@dotslashplay.it changed:
What |Removed |Added ---------------------------------------------------------------------------- Regression SHA1| |0cb79db12ac7c48477518dcff26 | |9ccc5d6b745e0
https://bugs.winehq.org/show_bug.cgi?id=49649
--- Comment #1 from vv221 vv221+winehq@dotslashplay.it --- I can confirm that a similar crash happens with Age of Empires 2, so this is most probably the same issue that first got reported in #47677.
https://bugs.winehq.org/show_bug.cgi?id=49649
vv221 vv221+winehq@dotslashplay.it changed:
What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.winehq.org/sho | |w_bug.cgi?id=47677
https://bugs.winehq.org/show_bug.cgi?id=49649
joaopa jeremielapuree@yahoo.fr changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |jeremielapuree@yahoo.fr
--- Comment #2 from joaopa jeremielapuree@yahoo.fr --- Does it happen with the demo https://www.01net.com/telecharger/windows/Jeux/jeux_strategie/fiches/244.htm... ?
https://bugs.winehq.org/show_bug.cgi?id=49649
--- Comment #3 from vv221 vv221+winehq@dotslashplay.it --- The Age of Empires demo uses a fixed resolution (800x600), the option to change it is proposed but if you try to use it you get a warning about resolution change being available only in the full game.
As I can not trigger a resolution change, there is no way to test if it would be affected by this regression.
https://bugs.winehq.org/show_bug.cgi?id=49649
--- Comment #4 from vv221 vv221+winehq@dotslashplay.it --- Star Wars: Galactic Battlegrounds is affected too.
I am going to go through the trial versions of both Age of Empires 2 and Star Wars: Galactic Battlegrounds to see if one of them gives an opportunity to trigger this crash.
https://bugs.winehq.org/show_bug.cgi?id=49649
--- Comment #5 from vv221 vv221+winehq@dotslashplay.it --- I can reliably reproduce this crash with the following free trial versions: - https://archive.org/details/AgeofEmpiresIITheAgeofKings_1020 - https://archive.org/details/AgeOfEmpiresIiTheConquerorsDemo - https://www.fileplanet.com/archive/p-2037/Star-Wars-Galactic-Battlegrounds-D...
The game menu is rendered in 800x600, and the default choice for gameplay resolution is 1024x768 (no way to change it in the demo). So a resolution change should happen when starting a new game, leading to the expected crash.
If commit 0cb79db12ac7c48477518dcff269ccc5d6b745e0 is reverted, said crash does not happen and the game starts fine.
https://bugs.winehq.org/show_bug.cgi?id=49649
--- Comment #6 from vv221 vv221+winehq@dotslashplay.it --- The crash on resolution change is triggered only when [HKEY_CURRENT_USER\Software\Wine\Direct3D] "renderer" is set to "gl". When set to "gdi" instead the resolution change happen with no error.
https://bugs.winehq.org/show_bug.cgi?id=49649
--- Comment #7 from vv221 vv221+winehq@dotslashplay.it --- Created attachment 67876 --> https://bugs.winehq.org/attachment.cgi?id=67876 Change Direct3D renderer to work around the crash
For convenience I provide this .reg file changing the Direct3D rendering method used by WINE in the current prefix.
It still needs more tests to make sure it is really effective and with no really bad side effects, but at least it seems to reliably work around the crash described here.
https://bugs.winehq.org/show_bug.cgi?id=49649
Paul Gofman pgofman@codeweavers.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |pgofman@codeweavers.com
--- Comment #8 from Paul Gofman pgofman@codeweavers.com --- Created attachment 67883 --> https://bugs.winehq.org/attachment.cgi?id=67883 Remove active client window from window data before deleting it.
Does the attached patch help by any chance? (I did not test with this game specifically.
https://bugs.winehq.org/show_bug.cgi?id=49649
--- Comment #9 from vv221 vv221+winehq@dotslashplay.it --- (In reply to Paul Gofman from comment #8)
Does the attached patch help by any chance? (I did not test with this game specifically.
This patch successfully avoids the crash on resolution change, but it either cause or reveal a rendering issue. I am going to attach a screenshot explaining it.
https://bugs.winehq.org/show_bug.cgi?id=49649
--- Comment #10 from vv221 vv221+winehq@dotslashplay.it --- Created attachment 67885 --> https://bugs.winehq.org/attachment.cgi?id=67885 Broken rendering screenshot
When using the patch proposed by Paul Gofman: https://bugs.winehq.org/show_bug.cgi?id=49649#c8
The crash on resolution change no longer happens, but it looks like the game is trying to display its full 1280x1024 surface in a 800x600 window. 1280x1024 being the set resolution for gameplay, and 800x600 the default one always used in menus.
https://bugs.winehq.org/show_bug.cgi?id=49649
Gijs Vermeulen gijsvrm@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Summary|Regression: X11 crash on |Multiple games cause X11 to |resolution change |crash on resolution change | |(Age of Empires 1 & 2, Star | |Wars: Galactic | |Battlegrounds) Keywords| |regression
https://bugs.winehq.org/show_bug.cgi?id=49649
Robert Walker bob.mt.wya@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |bob.mt.wya@gmail.com
https://bugs.winehq.org/show_bug.cgi?id=49649
François Gouget fgouget@codeweavers.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |fgouget@codeweavers.com Keywords| |patch
https://bugs.winehq.org/show_bug.cgi?id=49649
--- Comment #11 from joaopa jeremielapuree@yahoo.fr --- Works fine in wine-7/0-rc2. I tried the demo from comment 5. Can an administrator close this bug as FIXED?
https://bugs.winehq.org/show_bug.cgi?id=49649
vv221 vv221+winehq@dotslashplay.it changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED Resolution|--- |FIXED
--- Comment #12 from vv221 vv221+winehq@dotslashplay.it --- Using WINE 7.0-rc2 on top of a Debian Bookworm/Sid, with Mesa 21.2.6, I no longer get the reported issue with any of the following games: - Age of Empires 1 (CD-ROM) - Age of Empires 2 (CD-ROM) - Star Wars: Galactic Battlegrounds (gog.com)
https://bugs.winehq.org/show_bug.cgi?id=49649
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #13 from Alexandre Julliard julliard@winehq.org --- Closing bugs fixed in 7.0-rc4.