mirror of
https://github.com/ApfelTeeSaft/reactos.git
synced 2026-08-29 12:23:30 +00:00
don't crash on thread detach - now Diablo 2 videotest isn't crashing anymore
svn path=/trunk/; revision=31763
This commit is contained in:
@@ -91,6 +91,7 @@ OPENGL32_ThreadDetach()
|
||||
if (!HeapFree( GetProcessHeap(), 0, lpData ))
|
||||
DBGPRINT( "Warning: HeapFree() on GLTHREADDATA failed (%d)",
|
||||
GetLastError() );
|
||||
lpData = NULL;
|
||||
}
|
||||
|
||||
dispatchTable = NtCurrentTeb()->glTable;
|
||||
|
||||
@@ -978,6 +978,9 @@ rosglMakeCurrent( HDC hdc, HGLRC hglrc )
|
||||
|
||||
DBGTRACE( "Called!" );
|
||||
|
||||
if (OPENGL32_threaddata == NULL)
|
||||
return FALSE;
|
||||
|
||||
/* flush current context */
|
||||
if (OPENGL32_threaddata->glrc != NULL)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user