https://bugs.winehq.org/show_bug.cgi?id=6176
Anastasius Focht focht@gmx.net changed:
What |Removed |Added ---------------------------------------------------------------------------- URL|http://download.mcneel.com/ |http://www.cadcam-download. |s3/mcneel/rhino/3.0/eval/rh |de/download/solidedge/rh30e |30eval_en_20060331.exe |val.exe CC| |focht@gmx.net Component|-unknown |gdi32 Summary|Unhandled page fault when |Rhino 3D v3 (CAD app) |launching Rhino 3D v. 3 |crashes on startup | |(OpenGL/DIB driver needs to | |return max index for NULL | |PIXELFORMATDESCRIPTOR)
--- Comment #9 from Anastasius Focht focht@gmx.net --- Hello Austin,
I can confirm the crash - even with OSMesa. The CAD app indeed uses OpenGL bitmap support.
Relevant part of trace log:
--- snip --- $ pwd /home/focht/.wine/drive_c/Program Files/Rhinoceros 3.0 Evaluation/System
$ WINEDEBUG=+tid,+seh,+relay wine ./Rhino3.exe >>log.txt 2>&1 ... 0023:Call gdi32.CreateCompatibleDC(00000000) ret=00769428 0023:Ret gdi32.CreateCompatibleDC() retval=00010054 ret=00769428 0023:Call gdi32.GetDeviceCaps(00010054,0000000c) ret=0076943f 0023:Ret gdi32.GetDeviceCaps() retval=00000020 ret=0076943f 0023:Call gdi32.DescribePixelFormat(00010054,00000001,00000000,00000000) ret=0076945d 0023:Call opengl32.wglDescribePixelFormat(00010054,00000001,00000000,00000000) ret=7ec186b9 0023:Call gdi32.__wine_get_wgl_driver(00010054,0000000b) ret=7ed5b675 0023:Ret gdi32.__wine_get_wgl_driver() retval=7ec5b480 ret=7ed5b675 0023:Ret opengl32.wglDescribePixelFormat() retval=00000000 ret=7ec186b9 0023:Ret gdi32.DescribePixelFormat() retval=00000000 ret=0076945d 0023:Call gdi32.DeleteDC(00010054) ret=5f4038c2 0023:Ret gdi32.DeleteDC() retval=00000001 ret=5f4038c2 ... --- snip ---
The crash is just a late manifestation of the failing DescribePixelFormat() call.
Debug session:
--- snip --- Wine-dbg>n 153 if (size < sizeof(*descr)) return 0; Wine-dbg>bt Backtrace: =>0 0x7ebc1a2b dibdrv_wglDescribePixelFormat+0x2f(hdc=0x10054, fmt=0x1, size=0, descr=(nil)) [/home/focht/projects/wine/wine.repo/src/dlls/gdi32/dibdrv/opengl.c:153] in gdi32 (0x0033fa08) 1 0x7ed5c321 wglDescribePixelFormat+0x49(hdc=0x10054, format=0x1, size=0, descr=(nil)) [/home/focht/projects/wine/wine.repo/src/dlls/opengl32/wgl.c:409] in opengl32 (0x0033fa38) 2 0x7ec186b9 DescribePixelFormat+0x9e(hdc=<couldn't compute location>, fmt=<couldn't compute location>, size=<couldn't compute location>, pfd=<couldn't compute location>) [/home/focht/projects/wine/wine.repo/src/dlls/gdi32/opengl.c:89] in gdi32 (0x0033fa68) 3 0x0076945d in rhino3 (+0x36945c) (0x00010054) --- snip ---
The app wants to know the maximum pixel format index hence it passes NULL pixelformat descriptor. Wine doesn't handle this ...
Source: http://source.winehq.org/git/wine.git/blob/28be1f7853f01a402854dccdb9d0ee10a...
--- snip --- 148 static int dibdrv_wglDescribePixelFormat( HDC hdc, int fmt, UINT size, PIXELFORMATDESCRIPTOR *descr ) 149 { 150 int ret = sizeof(pixel_formats) / sizeof(pixel_formats[0]); 151 152 if (fmt <= 0 || fmt > ret) return ret; 153 if (size < sizeof(*descr)) return 0; 154 155 memset( descr, 0, sizeof(*descr) ); ... --- snip ---
If you fix this, the app runs farther (a splash screen is shown) - until the next crash Something MFC + user32 -> NULL GetParent() which looks familiar .. I've seen this earlier but can't remember the bug(s) right know.
$ sha1sum rh30eval.exe 8418bb80ae9bfb1f910f7c0c872424014d3da2f2 rh30eval.exe
$ du -sh rh30eval.exe 36M rh30eval.exe
$ wine --version wine-1.7.15
Regards