[PATCH 2/3] winex11: Make sure OpenGL is initialized when calling visual_from_fbconfig
Roderick Colenbrander
thunderbird2k at gmail.com
Mon May 10 08:36:32 CDT 2010
This fixes a part of bug 21804 where visual_from_fbconfig is called from some other
thread in which OpenGL wasn't initialized yet.
---
dlls/winex11.drv/opengl.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/dlls/winex11.drv/opengl.c b/dlls/winex11.drv/opengl.c
index 584abb6..e9896e8 100644
--- a/dlls/winex11.drv/opengl.c
+++ b/dlls/winex11.drv/opengl.c
@@ -3812,6 +3812,8 @@ XVisualInfo *visual_from_fbconfig_id( XID fbconfig_id )
WineGLPixelFormat *fmt;
XVisualInfo *ret;
+ if (!has_opengl()) return NULL;
+
fmt = ConvertPixelFormatGLXtoWGL(gdi_display, fbconfig_id, 0 /* no flags */);
if(fmt == NULL)
return NULL;
--
1.6.3.3
More information about the wine-patches
mailing list