Merge commit 'mesa_7_6_branch' into mesa_7_7_branch
[mesa.git] / src / mesa / shader / slang / slang_builtin.c
index 9ed8e3ecb39454f2ac1d7d061b72db42a20a0676..e5809509c93960fab5b01de9449cfded4368d2d8 100644 (file)
@@ -436,7 +436,7 @@ emit_statevars(const char *name, int array_len,
                struct gl_program_parameter_list *paramList)
 {
    if (type->type == SLANG_SPEC_ARRAY) {
-      GLint i, pos;
+      GLint i, pos = -1;
       assert(array_len > 0);
       if (strcmp(name, "gl_ClipPlane") == 0) {
          tokens[0] = STATE_CLIPPLANE;
@@ -741,7 +741,7 @@ static const struct input_info vertInputs[] = {
    { "gl_MultiTexCoord5", VERT_ATTRIB_TEX5, GL_FLOAT_VEC4, SWIZZLE_NOOP },
    { "gl_MultiTexCoord6", VERT_ATTRIB_TEX6, GL_FLOAT_VEC4, SWIZZLE_NOOP },
    { "gl_MultiTexCoord7", VERT_ATTRIB_TEX7, GL_FLOAT_VEC4, SWIZZLE_NOOP },
-   { NULL, 0, SWIZZLE_NOOP }
+   { NULL, 0, GL_NONE, SWIZZLE_NOOP }
 };
 
 /** Predefined fragment shader inputs */
@@ -752,10 +752,9 @@ static const struct input_info fragInputs[] = {
    { "gl_TexCoord", FRAG_ATTRIB_TEX0, GL_FLOAT_VEC4, SWIZZLE_NOOP },
    /* note: we're packing several quantities into the fogcoord vector */
    { "gl_FogFragCoord", FRAG_ATTRIB_FOGC, GL_FLOAT, SWIZZLE_XXXX },
-   { "gl_FogFragCoord", FRAG_ATTRIB_FOGC, GL_FLOAT, SWIZZLE_XXXX },
    { "gl_FrontFacing", FRAG_ATTRIB_FACE, GL_FLOAT, SWIZZLE_XXXX },
    { "gl_PointCoord", FRAG_ATTRIB_PNTC, GL_FLOAT_VEC2, SWIZZLE_XYZW },
-   { NULL, 0, SWIZZLE_NOOP }
+   { NULL, 0, GL_NONE, SWIZZLE_NOOP }
 };