https://bugs.winehq.org/show_bug.cgi?id=47409
Bug ID: 47409 Summary: odd behavior in several apps changing resolution after a crash Product: Wine Version: 4.11 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: winex11.drv Assignee: wine-bugs@winehq.org Reporter: galtgendo@o2.pl Distribution: ---
To make a thing clear: this isn't a GPU driver problem, over the years, I've seen this happen with a few different graphic cards using different drivers; also, while I'm opening this only now, the problem might be already over a decade old, just hard to trigger/notice, unless you're looking for it.
If an app that changes resolution crashes during resolution change, *some* of the time it leaves xserver in an inconsistent state, where despite running 'xrandr -s <foo>', the app that crashed can't be started again until xserver restart (as simply shutting down whole wine doesn't work).
If I start a second instance of the server, the app will start there without a problem there (that is, if no other problem occurs), but that leads to a different problem: if there are other wine apps running on the first display, another xerror triggered crash might happen.
Due to excessive randomness involved (and the need to trigger a crash in the first place), this is hard to reproduce *exactly*, yet in the past years I've seen it quite a few times. Also, to make it clear, I've seen this in many unrelated apps, their only common theme was changing resolution (and perhaps using directdraw, but I'm not sure about this part). Also, while not sure about it, IIRC, all of those apps didn't change the res back upon Alt-Tab - for some reason, I think this might be important.
xerror in the first case:
X Error of failed request: BadValue (integer parameter out of range for operation) Major opcode of failed request: 139 (RANDR) Minor opcode of failed request: 7 (RRSetScreenSize) Value in failed request: 0x0 Serial number of failed request: 438 Current serial number in output stream: 439
xerror in the second case:
X Error of failed request: BadWindow (invalid Window parameter) Major opcode of failed request: 10 (X_UnmapWindow) Resource id in failed request: 0x4c00003 Serial number of failed request: 322 Current serial number in output stream: 325
In the second case, it might simply be that wine caches DISPLAY value somewhere in the driver and tries to access first display with the resolution change, but no idea what's the first case, if xrandr is insufficient for a reset.
https://bugs.winehq.org/show_bug.cgi?id=47409
Zhiyi Zhang zzhang@codeweavers.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |zzhang@codeweavers.com
--- Comment #1 from Zhiyi Zhang zzhang@codeweavers.com --- I did encounter some RRSetScreenSize errors a few times, but not BadValue (integer parameter out of range for operation). More like legitimate values failing for some reasons. The major problem is that it can't be reproduced reliably. That way, I can't be sure what's wrong, let alone how to fix them.
For you second error, yes, Wine does cache DISPLAY values, for example, as gdi_display and display for each thread. But I don't see how it could relate to your error.