From cb132406ded760a622513cd1ab86bf83bb945671 Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Fri, 30 Oct 2009 13:28:44 -0700 Subject: [PATCH] i965: Add an index assert on get_fp_inst array like other compiler arrays. --- src/mesa/drivers/dri/i965/brw_wm_fp.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mesa/drivers/dri/i965/brw_wm_fp.c b/src/mesa/drivers/dri/i965/brw_wm_fp.c index 53fdd06f428..0e86d75deac 100644 --- a/src/mesa/drivers/dri/i965/brw_wm_fp.c +++ b/src/mesa/drivers/dri/i965/brw_wm_fp.c @@ -181,6 +181,7 @@ static void release_temp( struct brw_wm_compile *c, struct prog_dst_register tem static struct prog_instruction *get_fp_inst(struct brw_wm_compile *c) { + assert(c->nr_fp_insns < BRW_WM_MAX_INSN); return &c->prog_instructions[c->nr_fp_insns++]; } -- 2.30.2