[Mesa-dev] [PATCH 2/4] mesa: Resolve GCC missing field initializer warning.

Rhys Kidd rhyskidd at gmail.com
Tue Sep 8 03:21:47 PDT 2015


In file included from mesa/src/mesa/main/get.c:495:0:
mesa/src/mesa/main/get.c:190:37: warning: missing initializer for field 'extra' of 'const struct value_desc' [-Wmissing-field-initializers]
    LOC_ARRAY, type, offsetof(struct gl_vertex_array_object, field)
                                     ^
mesa/src/mesa/main/get_hash.h:179:39: note: in expansion of macro 'ARRAY_FIELD'
     { GL_POINT_SIZE_ARRAY_STRIDE_OES, ARRAY_FIELD(VertexAttrib[VERT_ATTRIB_POINT_SIZE].Stride, TYPE_INT) },
                                       ^
mesa/src/mesa/main/get.c:165:15: note: 'extra' declared here
    const int *extra;
               ^

Signed-off-by: Rhys Kidd <rhyskidd at gmail.com>
---
 src/mesa/main/get_hash_params.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/mesa/main/get_hash_params.py b/src/mesa/main/get_hash_params.py
index 477efe0..26d1c2f 100644
--- a/src/mesa/main/get_hash_params.py
+++ b/src/mesa/main/get_hash_params.py
@@ -236,7 +236,7 @@ descriptor=[
 # OES_point_size_array
   [ "POINT_SIZE_ARRAY_OES", "ARRAY_FIELD(VertexAttrib[VERT_ATTRIB_POINT_SIZE].Enabled, TYPE_BOOLEAN)" ],
   [ "POINT_SIZE_ARRAY_TYPE_OES", "ARRAY_FIELD(VertexAttrib[VERT_ATTRIB_POINT_SIZE].Type, TYPE_ENUM)" ],
-  [ "POINT_SIZE_ARRAY_STRIDE_OES", "ARRAY_FIELD(VertexAttrib[VERT_ATTRIB_POINT_SIZE].Stride, TYPE_INT)" ],
+  [ "POINT_SIZE_ARRAY_STRIDE_OES", "ARRAY_FIELD(VertexAttrib[VERT_ATTRIB_POINT_SIZE].Stride, TYPE_INT), NO_EXTRA" ],
   [ "POINT_SIZE_ARRAY_BUFFER_BINDING_OES", "LOC_CUSTOM, TYPE_INT, 0, NO_EXTRA" ],
 ]},
 
-- 
2.1.4



More information about the mesa-dev mailing list