glsl: Fail linking if assign_attribute_locations fails

This commit is contained in:
Ian Romanick 2010-10-07 17:20:15 -07:00
parent 3b16c591a4
commit 4b5489dd6f

View file

@ -1486,8 +1486,10 @@ link_shaders(GLcontext *ctx, struct gl_shader_program *prog)
* FINISHME: GL_MAX_VERTEX_ATTRIBS. GL_MAX_VERTEX_ATTRIBS must be
* FINISHME: at least 16, so hardcode 16 for now.
*/
if (!assign_attribute_locations(prog, 16))
if (!assign_attribute_locations(prog, 16)) {
prog->LinkStatus = false;
goto done;
}
if (prog->_NumLinkedShaders == 1)
demote_unread_shader_outputs(prog->_LinkedShaders[0]);