Fixed possible crash on exit

This commit is contained in:
Jens Hemprich 2007-08-25 19:02:54 +00:00
parent 47d8b84733
commit 23b0ee801d
1 changed files with 6 additions and 3 deletions

View File

@ -544,9 +544,12 @@ grSstWinClose( void )
RenderFree(); RenderFree();
FinaliseOpenGLWindow(); FinaliseOpenGLWindow();
FreeFrameBuffer(Glide.FrameBuffer.Address); if (Glide.FrameBuffer.Address)
Glide.FrameBuffer.Address = NULL; {
Glide.TempBuffer.Address = NULL; FreeFrameBuffer(Glide.FrameBuffer.Address);
Glide.FrameBuffer.Address = NULL;
Glide.TempBuffer.Address = NULL;
}
// Freeing the readbuffer is be deferred until // Freeing the readbuffer is be deferred until
// reopening the window or unloading the library // reopening the window or unloading the library
} }