Dear Maintainer,
On Debian Buster, Wine was able to run Microsoft Flight Simulator 2004.
After upgrading to Bullseye, it no longer does: when starting Flight Simulator,
the loading screen appears, and then sometimes the main window for a fraction
of a second, and then the application crashes. When doing this in a terminal
window ("wine fs9.exe" in its installation directory), the following error is
visible in the output:
X Error of failed request: BadWindow (invalid Window parameter)
Major opcode of failed request: 12 (X_ConfigureWindow)
Resource id in failed request: 0x3800157
Serial number of failed request: 992
Current serial number in output stream: 1011
I am aware that Wine does not yet run all windows applications yet, but since
Flight Simulator worked nicely in Buster's wine version, I did not expect this
regression. Since a lot of things have probably been upgraded in the Buster ->
Bullseye upgrade, I am not sure which changes cause this: wine itself, the
window manager, graphics drivers, maybe even the kernel? Wine seems like the
first suspect though.
I tested some OpenGL games supplied with Debian, and they worked fine. I tested
Flight Simulator in another desktop environment (blackbox instead of MATE),
that still gives the same error. I used "winecfg" to try different graphics
settings (including dektop mode); that still gives the same error (note that
winecfg itself works fine, without crashing). I still need to test whether
other windows games work within wine.
I tried the following:
WINEDEBUG=+x11drv wine fs9.exe 2>&1 | tee ~/winetrace.txt
and the output (including the above error) is in the attachment. I also tried
this with "WINEDEBUG=+x11drv,+synchronous", but that seemed to trigger another
kind of crash, so the output didn't look so useful.
If I have time I'll keep on puzzling, doing more tests, reading the source,
learning the X11 protocol & so on. If you have any suggestions / fixes, please
let me know.
I have some further test results: Red Alert, Splinter Cell and GTA III work without issues (at least without this particular issue). Age of Empires II results in the same error, but only once you switch from the game menus to the game itself. In my set-up, the screen resolution of the game itself is different from the menus. Since I tested Age of Empires II in desktop mode, the resolution change should have resulted in a desktop window resize - as it did before the Debian dist upgrade. However, it now results in the same crash as Flight Simulator.
Le 07/01/2022 à 16:30, C.J. Plooy a écrit : It is fixed on current 7.0 release candidate, and you can work around it with older WINE builds by changing the Direct3D renderer as described in this post: https://bugs.winehq.org/show_bug.cgi?id=49649#c6 (a .reg file applying the suggested change is provided for convenience)
Antoine Le Gonidec schreef op vr 07-01-2022 om 17:04 [+0100]: my problem! I tried changing the Direct3D renderer with "wine regedit". Initially, that registry value was not set on my system - I tested with absent value, with "gdi" and with "gl". These are the results: ===results TLDR=== The workaround works for Age of Empires II but not for Flight Simulator 2004, where it results in a different error. I think Flight Simulator uses Direct3D and Age of Empires doesn't, and the workaround disables Direct3D. ===results details=== With "gdi", the terminal window shows a line "0009:err:winediag:wined3d_dll_init Disabling 3D support.". Unlike before, Flight Simulator now shows its menu(*). However, when I press the button to start flying, it shows an error window with the text "Error creating required Direct3D buffers - Flight Simulator will now exit.", and the game exits. With "gdi", Age of Empires II shows the same line on the terminal, but it works fine. I guess it helps that AoE isn't really a 3D game. With "gl", the terminal window shows a line "0009:err:winediag:wined3d_dll_init Using the OpenGL renderer.". While this line was not present with absent registry key, the behavior is the same: AoE and Flight Simulator crash, as in my original bug report. ===results end=== I suppose the good news is that we know how Wine 7 is patched to fix the issue - maybe Wine 5 can be patched in a similar way. I'd have to look into how to compile Debian's Wine package from source though, and I hope it won't take too long compiling. (*) For people trying to reproduce this: in my case, it starts with a menu page that does not show any 3D elements (the "select flight" menu). I can imagine it still crashes if on your system it starts with the "create flight" menu, which does contain 3D elements.
I created the attached patch, based on an upstream patch. I re-compiled the Wine packages with this patch, and tested it. It prevents Flight Simulator 2004 and Age of Empires II from crashing. In AoE, the game is playable, though in my case the window contents wasn't correctly sized to the (Wine desktop) window size; this might be specific to my current set-up though, and I could do more testing. In FS, the menu is usable, but when flying, the screen contents is garbage, and the 3D elements (environment and also cockpit elements) are not drawn. The window menu *is* visible. The game is not crashed though, and based on the sounds, it does respond as expected to keyboard input. Note: I used a VM with i386 Debian 11 installed to compile the i386 Wine packages. Getting the wine packages compiled took a lot more effort than creating the patch for this Wine version.
Please ignore the patch in my previous mail. I created the new patch attached here, and it fixes this bug for me. The patch reverts commit 0cb79db12ac7c48477518dcff269ccc5d6b745e0, which was reported in the upstream discussion[1] to introduce the bug. Unfortunately, the reverted commit was intended to fix another bug[2], so it might be that, by reverting the commit, the other bug[2] may be re-introduced. Luckily, I am not affected by that other bug, so I am much better off with this patch. The other bug was open for more than 10 years, so apparently, it was never a high priority for the developers. I'd say that the other bug, which may be re-introduced by this patch, is a pretty minor one. It may be of interest that the latest version of the Wine source code (version 7.0+) does not seem to contain code from commit 0cb79db12ac7c48477518dcff269ccc5d6b745e0. [1] https://bugs.winehq.org/show_bug.cgi?id=49649 [2] https://bugs.winehq.org/show_bug.cgi?id=15232
We believe that the bug you reported is fixed in the latest version of
wine, which is due to be installed in the Debian FTP archive.
A summary of the changes between this version and the previous one is
attached.
Thank you for reporting the bug, which will now be closed. If you
have further comments please address them to 1002023@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.
Debian distribution maintenance software
pp.
Michael Gilbert <mgilbert@debian.org> (supplier of updated wine package)
(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)
Format: 1.8
Date: Sun, 05 Jun 2022 21:54:23 +0000
Source: wine
Architecture: source
Version: 7.0~repack-1
Distribution: unstable
Urgency: medium
Maintainer: Debian Wine Party <debian-wine@lists.debian.org>
Changed-By: Michael Gilbert <mgilbert@debian.org>
Closes: 1002023 1007913
Changes:
wine (7.0~repack-1) unstable; urgency=medium
.
* New upstream release 7.0, released Jan 18, 2022 (closes: #1007913).
- Fix crash during resolution change in a few games (closes: #1002023).
Checksums-Sha1:
039ecc86de781a9b0dd3ab72b0c1fe85e6ab8d50 4510 wine_7.0~repack-1.dsc
7c6cc8bebb2c135ff61e05e8cae4a2c87ea1b8b2 24268624 wine_7.0~repack.orig.tar.xz
9b1fd6779e2526c4c9f9c129c9c276f5643a2ce8 5719660 wine_7.0~repack-1.debian.tar.xz
3ba2a1ad7a013811760c5a26219582d3a371ae92 19279 wine_7.0~repack-1_source.buildinfo
Checksums-Sha256:
e6f10df199873cbd392101ba64d3dd967448d800f786255acc633765e90c89b2 4510 wine_7.0~repack-1.dsc
ce32944527a57999ceecde0fcf545c90748cc5a0847dac4d376b6ff0b409b6ae 24268624 wine_7.0~repack.orig.tar.xz
1946a1a1ff732046fbb73865cbcfce0d5cb2afdc46b398b221b61c0b6b602894 5719660 wine_7.0~repack-1.debian.tar.xz
af461bf7304f8112c871ff2ab66586cd419175af01197ee003e974bd32d22e88 19279 wine_7.0~repack-1_source.buildinfo
Files:
32b2e4e620bcc9c197f956c38e2c208d 4510 otherosfs optional wine_7.0~repack-1.dsc
615837298e82a0e8e492bc246d4150ac 24268624 otherosfs optional wine_7.0~repack.orig.tar.xz
4a78379f581e7727cc5526f6df2e8411 5719660 otherosfs optional wine_7.0~repack-1.debian.tar.xz
d12f797c9b06111e58de14b6feb3fb61 19279 otherosfs optional wine_7.0~repack-1_source.buildinfo
-----BEGIN PGP SIGNATURE-----
iQQzBAEBCgAdFiEEIwTlZiOEpzUxIyp4mD40ZYkUaygFAmKdUpQACgkQmD40ZYkU
aygUPh/+IXRRqyPfxJ8oq6o3iBLDOMfphiOpwNxmRYHhDptAKB64yP/91LU9Slpl
UuZbnX8gCkb2edIXyF/d3f2ugtWcbEAi5eJei8OW4Q/0eExq3ayfeAIz+PERKldF
sJZIIVFymX+pPVa+iHqaDKBRGeLBIIiq9Z2kxdeFjOWMR6LioAtzQXLLNNakMesT
pLncxxpefrvzGggIzVolqxG02H2r3ZLYZXxzFIbDg49EB8NAGGk4M95IaiZHdN98
sA/MAoYSiLW5H6yBoVrHAoIdSi4o9e18i5NxDpQ3TagRv3PlV0skyfFU3gnkqqVn
0fRb8N//4XVgCzyU0KsDJwp3jbs5CAUQb44Wkjpu1y/18ChG2HPaQwDKgFpNjAGw
vCLZkYVp9QFJo8r2mLLaUA7bEnjB9ZQfrl2UIIJlzGYPsdPdJuLEB4VS5Si3Mc+9
F8czBVw1535aDqofXUTM6YqPbg3+KJyAcBcbeAb3I6N68ZPwmAY16UaUzCnGBGjC
QGjs7ey6p2QOT4f5hqPMmueW4EQbOPtxmyIvOICCQ/fr03Yv04OuIWaqZqq1c2dl
GRgIqEcm0wX8mi6hT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