Fixed the OpenGL detection code.