r500: add missing brackets around depth testing
authorDave Airlie <airlied@linux.ie>
Sun, 1 Jun 2008 21:18:21 +0000 (07:18 +1000)
committerDave Airlie <airlied@linux.ie>
Sun, 1 Jun 2008 21:18:21 +0000 (07:18 +1000)
src/mesa/drivers/dri/r300/r500_fragprog.c

index d5ae4a5f749b7584a610d59498ab88ec0377d47d..b967aa2d7376e2439289b9cbc8f7db402c8b6692 100644 (file)
@@ -364,10 +364,11 @@ static void emit_alu(struct r500_fragment_program *fp, int counter, struct prog_
                if (fpi->DstReg.Index == FRAG_RESULT_COLR)
                        fp->inst[counter].inst0 |= (fpi->DstReg.WriteMask << 15);
 
-               if (fpi->DstReg.Index == FRAG_RESULT_DEPR)
+               if (fpi->DstReg.Index == FRAG_RESULT_DEPR) {
                        fp->inst[counter].inst4 |= R500_ALPHA_W_OMASK;
                        /* Notify the state emission! */
                        fp->writes_depth = GL_TRUE;
+               }
        } else {
                fp->inst[counter].inst0 = R500_INST_TYPE_ALU
                        /* pixel_mask */