glsl: fix heap-buffer-overflow
[mesa.git] / src / compiler / shader_info.h
index 181f85febac26adcd4b2e6a50d32452f5cac5f73..a67084156dd03d77988180b1deed6e009cce00bc 100644 (file)
@@ -142,17 +142,17 @@ typedef struct shader_info {
          unsigned shared_size;
       } cs;
 
+      /* Applies to both TCS and TES. */
       struct {
          /** The number of vertices in the TCS output patch. */
-         unsigned vertices_out;
-      } tcs;
+         unsigned tcs_vertices_out;
 
-      struct {
          uint32_t primitive_mode; /* GL_TRIANGLES, GL_QUADS or GL_ISOLINES */
-         uint32_t spacing;        /* GL_EQUAL, GL_FRACTIONAL_EVEN, GL_FRACTIONAL_ODD */
-         uint32_t vertex_order;   /* GL_CW or GL_CCW */
+         enum gl_tess_spacing spacing;
+         /** Is the vertex order counterclockwise? */
+         bool ccw;
          bool point_mode;
-      } tes;
+      } tess;
    };
 } shader_info;