http://bugs.winehq.org/show_bug.cgi?id=28958
Bug #: 28958 Summary: Rayman 2 demo crashes on screen resolution change Product: Wine Version: 1.3.31 Platform: x86 URL: ftp://ftp.ubisoft.com/Rayman2/rayman2high.zip OS/Version: Linux Status: NEW Keywords: download, regression Severity: normal Priority: P2 Component: gdi32 AssignedTo: wine-bugs@winehq.org ReportedBy: gyebro69@gmail.com CC: julliard@winehq.org Classification: Unclassified Regression SHA1: 885a4a5c089c2ce8f30a5d041d423f1386cb46ed
Created attachment 37235 --> http://bugs.winehq.org/attachment.cgi?id=37235 terminal output
Steps to reproduce the problem:
0. Native dinput.dll is needed, otherwise there is no keyboard input at all in the game (bug #21159). I also had to set up a virtual desktop because the game didn't appear correctly in full screen mode. 1. Extract the archive and install the demo. Launch the installed demo by Rayman2Demo.exe 2. Go to Options > Video menu and select a different screen size >> the game will crash.
This is with the default Opengl renderer. With ddr=gdi, the demo crashes instantly after started.
The attached log was created by Wine-1.3.31. The crash is still present in wine-1.3.31-213-g996b451, but it doesn't generate a backtrace.
Changing the screen resolution is possible with 1.3.30, and the result of the regression test:
885a4a5c089c2ce8f30a5d041d423f1386cb46ed is the first bad commit commit 885a4a5c089c2ce8f30a5d041d423f1386cb46ed Author: Alexandre Julliard julliard@winehq.org Date: Tue Oct 18 11:44:41 2011 +0200
gdi32: Add an initial Freetype font driver.
:040000 040000 1d7a46fd489d29432ef0bfaa55af54a8a737c55c 548003f46f390910b31b3c538b5e360f3c6204b8 M dlls
The patch cannot be reverted on wine-1.3.31-213-g996b451, not even on 1.3.31: Unreversed patch detected!
git checkout 885a4a5c089c2ce8f30a5d041d423f1386cb46ed >> crash git reset --hard HEAD^ >> no crash, changing the resolution succeeded
Fedora 15 x86 Gnome 3 Nvidia 250 / driver 280.13 freetype-freeworld-2.4.4-5.fc15.i686 freetype-devel-2.4.4-5.fc15.i686 freetype-2.4.4-5.fc15.i686
http://bugs.winehq.org/show_bug.cgi?id=28958
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Component|gdi32 |directx-d3d
--- Comment #1 from Alexandre Julliard julliard@winehq.org 2011-11-01 07:03:25 CDT --- Looks like d3d is using a deleted context or some sort of similar memory corruption. I doubt it has anything to do with FreeType.
http://bugs.winehq.org/show_bug.cgi?id=28958
--- Comment #2 from GyB gyebro69@gmail.com 2011-11-01 07:08:06 CDT --- (In reply to comment #1)
Looks like d3d is using a deleted context or some sort of similar memory corruption. I doubt it has anything to do with FreeType.
Yes, the backtrace looked weird to me as well...is it reproducible on your side as well?
http://bugs.winehq.org/show_bug.cgi?id=28958
--- Comment #3 from Alexandre Julliard julliard@winehq.org 2011-11-01 07:13:47 CDT --- Yes, but it's sort of random, sometimes it works, depending on timings and tracing options.
http://bugs.winehq.org/show_bug.cgi?id=28958
Henri Verbeet hverbeet@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |hverbeet@gmail.com
http://bugs.winehq.org/show_bug.cgi?id=28958
--- Comment #4 from maikwagner@yahoo.com 2011-11-03 10:15:20 CDT --- Created attachment 37271 --> http://bugs.winehq.org/attachment.cgi?id=37271 Output wine 1.3.28 on Ubuntu Oneiric
I am also having trouble getting the demo to run. I am using an older version of wine (1.3.28) and have attached my output. Hope this helps.
http://bugs.winehq.org/show_bug.cgi?id=28958
--- Comment #5 from GyB gyebro69@gmail.com 2011-11-03 11:04:29 CDT --- (In reply to comment #4)
Created attachment 37271 [details] Output wine 1.3.28 on Ubuntu Oneiric
I am also having trouble getting the demo to run. I am using an older version of wine (1.3.28) and have attached my output. Hope this helps.
This bug first appeared in Wine-1.3.31 and occurs when changing the screen resolution. Your problem in Rayman 2 must be a different issue (probably related to the Intel gfx card/driver you're using). Feel free to open a separate bug report for that.
http://bugs.winehq.org/show_bug.cgi?id=28958
--- Comment #6 from Matteo Bruni matteo.mystral@gmail.com 2011-11-03 14:34:02 CDT --- Created attachment 37275 --> http://bugs.winehq.org/attachment.cgi?id=37275 Store gl_info into the wined3d_context
I debugged this one for a while. Apparently we get the crashes because when we destroy the wined3d context, the wined3d_gl_info they point to may be gone.
This patch keeps a separate copy of gl_info into each context. It should fix the bug, but as you can see the patch is quite "invasive", not sure about the approach.
This issue is valid and may affect other applications too, but notice that this demo is buggy with regard to resolution changes: it leaks memory each time you change resolution and even the included readme.txt admits that changing resolution in the menus can hang the game...
http://bugs.winehq.org/show_bug.cgi?id=28958
Matteo Bruni matteo.mystral@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Attachment #37275|0 |1 is obsolete| |
--- Comment #7 from Matteo Bruni matteo.mystral@gmail.com 2011-11-03 15:06:41 CDT --- Created attachment 37277 --> http://bugs.winehq.org/attachment.cgi?id=37277 Store gl_info into the wined3d_context - take 2
Indeed (thanks Henri) this patch does the same thing as the previous one in about a tenth of the size...
http://bugs.winehq.org/show_bug.cgi?id=28958
--- Comment #8 from GyB gyebro69@gmail.com 2011-11-03 22:44:31 CDT --- (In reply to comment #7)
Created attachment 37277 [details] Store gl_info into the wined3d_context - take 2
Indeed (thanks Henri) this patch does the same thing as the previous one in about a tenth of the size...
The patch worked here, and changing the screen resolution didn't cause a crash (patch was applied on wine-1.3.31-320-gc872590).
http://bugs.winehq.org/show_bug.cgi?id=28958
--- Comment #9 from Austin English austinenglish@gmail.com 2011-11-15 14:39:33 CST --- (In reply to comment #8)
(In reply to comment #7)
Created attachment 37277 [details] Store gl_info into the wined3d_context - take 2
Indeed (thanks Henri) this patch does the same thing as the previous one in about a tenth of the size...
The patch worked here, and changing the screen resolution didn't cause a crash (patch was applied on wine-1.3.31-320-gc872590).
http://source.winehq.org/git/wine.git/commitdiff/1fd18d768845ab8ec965a57c5a8...
please retest.
http://bugs.winehq.org/show_bug.cgi?id=28958
GyB gyebro69@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Fixed by SHA1| |1fd18d768845ab8ec965a57c5a8 | |783aba1cc0c68 Status|NEW |RESOLVED Resolution| |FIXED
--- Comment #10 from GyB gyebro69@gmail.com 2011-11-15 14:53:24 CST --- Indeed, no crash in today's git (wine-1.3.32-277-ge7bbb4e).
http://bugs.winehq.org/show_bug.cgi?id=28958
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #11 from Alexandre Julliard julliard@winehq.org 2011-11-18 13:05:08 CST --- Closing bugs fixed in 1.3.33.