mojoshader.c
changeset 1050 56b06b1ebb27
parent 1049 ac4c2e745802
child 1052 0ac978521113
--- a/mojoshader.c	Thu Jun 02 00:51:50 2011 -0400
+++ b/mojoshader.c	Thu Jun 02 03:17:18 2011 -0400
@@ -7419,8 +7419,8 @@
                 case 7:
                 {
                     operand->type = MOJOSHADER_PRESHADEROPERAND_TEMP;
-                    if (operand->index > preshader->temp_count)
-                        preshader->temp_count = operand->index;
+                    if (operand->index >= preshader->temp_count)
+                        preshader->temp_count = operand->index + 1;
                     break;
                 } // case
             } // switch