From: Brian Paul Date: Fri, 3 Apr 2009 15:00:06 +0000 (-0600) Subject: mesa: replace assertion with conditional in _mesa_opcode_string() X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=5c5d78e1918fedb6fd43f5fafdba2a142a09d56f;p=mesa.git mesa: replace assertion with conditional in _mesa_opcode_string() --- diff --git a/src/mesa/shader/prog_instruction.c b/src/mesa/shader/prog_instruction.c index 6a21152c60b..ca7565c0911 100644 --- a/src/mesa/shader/prog_instruction.c +++ b/src/mesa/shader/prog_instruction.c @@ -291,7 +291,9 @@ _mesa_is_tex_instruction(gl_inst_opcode opcode) const char * _mesa_opcode_string(gl_inst_opcode opcode) { - ASSERT(opcode < MAX_OPCODE); - return InstInfo[opcode].Name; + if (opcode < MAX_OPCODE) + return InstInfo[opcode].Name; + else + return "OP?"; }