mirror of
https://github.com/glfw/glfw.git
synced 2024-11-22 04:54:35 +00:00
Removed superfluous nonsense, added platform terminate call on failed platform init.
This commit is contained in:
parent
86c6023daa
commit
0ba1cf9c59
@ -50,9 +50,11 @@ GLFWAPI int glfwInit(void)
|
||||
memset(&_glfwLibrary, 0, sizeof(_glfwLibrary));
|
||||
|
||||
if (!_glfwPlatformInit())
|
||||
{
|
||||
_glfwPlatformTerminate();
|
||||
return GL_FALSE;
|
||||
}
|
||||
|
||||
// From now on, GLFW state is valid
|
||||
_glfwInitialized = GL_TRUE;
|
||||
|
||||
return GL_TRUE;
|
||||
@ -71,7 +73,6 @@ GLFWAPI void glfwTerminate(void)
|
||||
if (!_glfwPlatformTerminate())
|
||||
return;
|
||||
|
||||
// GLFW is no longer initialized
|
||||
_glfwInitialized = GL_FALSE;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user