[PATCH 1/3] winex11.drv: Check the current context in X11DRV_wglMakeCurrent().

Roderick Colenbrander thunderbird2k at gmail.com
Fri Sep 18 08:54:45 CDT 2009


Hi,

I'm not sure if we should skip the glXMakeCurrent(null, null) call in
GLX as in case of GLX it doesn't hurt. Second I'm not sure if we need
to put the SetLastError code in winex11 or in gdi32/opengl.c. I think
it should be in there as we don't need any X11 info.

Roderick

2009/9/18 Rico Schüller <kgbricola at web.de>:
> Hi,
>
> this patch series fixes a bug which happens on windows with wined3d. There a
> second call to wglMakeCurrent(NULL, NULL) fails, which will in one case
> result in an early return in context_set_current(), which doesn't set the
> the current context to NULL in such a case, but frees the variable. So on
> the next call to context_set_current() (e.g. from
> WineD3D_CreateFakeGLContext()) the memory in old->... could be some other
> random memory and the app could crash.
>
> The first patch adds a fix for winex11.drv to change the behaviour to the
> one on xp. The second patch adds a test case to opengl32/tests. And the
> third one fixes the behaviour in wined3d.
>
> Cheers
> Rico
>
> ---
>  dlls/winex11.drv/opengl.c |   13 +++++++++++--
>  1 files changed, 11 insertions(+), 2 deletions(-)
>
>
>
>
>
>



More information about the wine-patches mailing list