mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-26 03:30:22 +01:00
Remove bad assertions, decrement NumShaders in _mesa_detach_shader().
Fixes crashes w/ Brad King's depth peeling test.
This commit is contained in:
parent
f3e8c32376
commit
bac15c8db8
1 changed files with 1 additions and 2 deletions
|
|
@ -309,8 +309,6 @@ _mesa_lookup_shader(GLcontext *ctx, GLuint name)
|
|||
* what we're expecting.
|
||||
*/
|
||||
if (sh && sh->Type == GL_SHADER_PROGRAM_MESA) {
|
||||
assert(sh->Type == GL_VERTEX_SHADER ||
|
||||
sh->Type == GL_FRAGMENT_SHADER);
|
||||
return NULL;
|
||||
}
|
||||
return sh;
|
||||
|
|
@ -576,6 +574,7 @@ _mesa_detach_shader(GLcontext *ctx, GLuint program, GLuint shader)
|
|||
_mesa_free(shProg->Shaders);
|
||||
|
||||
shProg->Shaders = newList;
|
||||
shProg->NumShaders = n - 1;
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue