Commit 2463db9b authored by hybrid's avatar hybrid

Fix count value to 0 if extension is unsupported or context is gone. Fixes a bug found by hendu.

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@3695 dfc29bdd-3216-0410-991c-e03cc46cb475
parent 81e59495
......@@ -1506,6 +1506,7 @@ inline void COpenGLExtensionHandler::extGlDeleteShader(GLuint shader)
inline void COpenGLExtensionHandler::extGlGetAttachedObjects(GLhandleARB program, GLsizei maxcount, GLsizei* count, GLhandleARB* shaders)
{
*count=0;
#ifdef _IRR_OPENGL_USE_EXTPOINTER_
if (pGlGetAttachedObjectsARB)
pGlGetAttachedObjectsARB(program, maxcount, count, shaders);
......@@ -1518,6 +1519,7 @@ inline void COpenGLExtensionHandler::extGlGetAttachedObjects(GLhandleARB program
inline void COpenGLExtensionHandler::extGlGetAttachedShaders(GLuint program, GLsizei maxcount, GLsizei* count, GLuint* shaders)
{
*count=0;
#ifdef _IRR_OPENGL_USE_EXTPOINTER_
if (pGlGetAttachedShaders)
pGlGetAttachedShaders(program, maxcount, count, shaders);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment