delete both shaders on failure
This commit is contained in:
parent
fd4a893729
commit
51d499758d
2 changed files with 3 additions and 2 deletions
|
@ -182,7 +182,10 @@ GLuint OpenGL_BuildProgram(const GLchar *vertSource, const GLchar *fragSource)
|
|||
if (isCompiled == GL_FALSE)
|
||||
{
|
||||
if (glDeleteShader)
|
||||
{
|
||||
glDeleteShader(fragShader);
|
||||
glDeleteShader(vertShader);
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue