glsl/glcpp: initialize all fields of glcpp_parser_t on creation
authorTapani Pälli <tapani.palli@intel.com>
Thu, 13 Oct 2016 11:54:30 +0000 (14:54 +0300)
committerMarek Olšák <marek.olsak@amd.com>
Mon, 31 Oct 2016 10:53:38 +0000 (11:53 +0100)
this fixes some of the regressions with
"ralloc: remove memset from ralloc_size"

Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
Signed-off-by: Marek Olšák <marek.olsak@amd.com>
src/compiler/glsl/glcpp/glcpp-parse.y

index 4fd1448fb4d5ca5d14742b69eae089a0f71819d7..5bf0606d40ef3e677b3d6a0de097091c7c336a8d 100644 (file)
@@ -1351,6 +1351,7 @@ glcpp_parser_create(glcpp_extension_iterator extensions, void *state, gl_api api
                                              _mesa_key_string_equal);
    parser->active = NULL;
    parser->lexing_directive = 0;
+   parser->lexing_version_directive = 0;
    parser->space_tokens = 1;
    parser->last_token_was_newline = 0;
    parser->last_token_was_space = 0;
@@ -1382,6 +1383,8 @@ glcpp_parser_create(glcpp_extension_iterator extensions, void *state, gl_api api
    parser->has_new_source_number = 0;
    parser->new_source_number = 0;
 
+   parser->is_gles = false;
+
    return parser;
 }