summaryrefslogtreecommitdiff
path: root/src/mesa/shader/program.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/shader/program.c')
-rw-r--r--src/mesa/shader/program.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/mesa/shader/program.c b/src/mesa/shader/program.c
index 5d21cff672..37962f0e9b 100644
--- a/src/mesa/shader/program.c
+++ b/src/mesa/shader/program.c
@@ -372,7 +372,11 @@ _mesa_reference_program(GLcontext *ctx,
assert(ptr);
if (*ptr && prog) {
/* sanity check */
- ASSERT((*ptr)->Target == prog->Target);
+ if ((*ptr)->Target == GL_VERTEX_PROGRAM_ARB)
+ ASSERT(prog->Target == GL_VERTEX_PROGRAM_ARB);
+ else if ((*ptr)->Target == GL_FRAGMENT_PROGRAM_ARB)
+ ASSERT(prog->Target == GL_FRAGMENT_PROGRAM_ARB ||
+ prog->Target == GL_FRAGMENT_PROGRAM_NV);
}
if (*ptr == prog) {
return; /* no change */