1
0
Fork 0
mirror of https://github.com/gwm17/glfw.git synced 2024-11-23 10:48:51 -05:00

Removed check for invalid user, added error setting.

This commit is contained in:
Camilla Berglund 2012-08-02 15:29:13 +02:00
parent bfc746a847
commit ee3304c09a

View File

@ -589,7 +589,6 @@ GLFWAPI int glfwExtensionSupported(const char* extension)
{
const GLubyte* extensions;
_GLFWwindow* window;
GLubyte* where;
GLint count;
int i;
@ -606,10 +605,11 @@ GLFWAPI int glfwExtensionSupported(const char* extension)
return GL_FALSE;
}
// Extension names should not have spaces
where = (GLubyte*) strchr(extension, ' ');
if (where || *extension == '\0')
if (extension == NULL || *extension == '\0')
{
_glfwSetError(GLFW_INVALID_VALUE, NULL);
return GL_FALSE;
}
if (window->glMajor < 3)
{