diff options
author | marha <marha@users.sourceforge.net> | 2013-07-16 08:55:45 +0200 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2013-07-16 08:55:45 +0200 |
commit | 707c146a74f6ff862be3ebb2470d1f31e29dd907 (patch) | |
tree | 59f570f7b1f38bb459308b5d13d1aae922ffff3d /mesalib/src/glsl/glsl_symbol_table.cpp | |
parent | 8b38c5a02fec73bd9cd070399d717bb32ac46bfb (diff) | |
download | vcxsrv-707c146a74f6ff862be3ebb2470d1f31e29dd907.tar.gz vcxsrv-707c146a74f6ff862be3ebb2470d1f31e29dd907.tar.bz2 vcxsrv-707c146a74f6ff862be3ebb2470d1f31e29dd907.zip |
solved compilation problem
Diffstat (limited to 'mesalib/src/glsl/glsl_symbol_table.cpp')
-rw-r--r-- | mesalib/src/glsl/glsl_symbol_table.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/mesalib/src/glsl/glsl_symbol_table.cpp b/mesalib/src/glsl/glsl_symbol_table.cpp index f9c84e86e..94a5d5747 100644 --- a/mesalib/src/glsl/glsl_symbol_table.cpp +++ b/mesalib/src/glsl/glsl_symbol_table.cpp @@ -182,7 +182,7 @@ bool glsl_symbol_table::add_type(const char *name, const glsl_type *t) bool glsl_symbol_table::add_type_ast(const char *name, const class ast_type_specifier *a) { symbol_table_entry *entry = new(mem_ctx) symbol_table_entry(a); - char ast_name[strlen("#ast.") + strlen(name) + 1]; + char *ast_name=(char*)alloca(strlen("#ast.") + strlen(name) + 1); strcpy(ast_name, "#ast."); strcat(ast_name + strlen("#ast."), name); return _mesa_symbol_table_add_symbol(table, -1, ast_name, entry) == 0; @@ -241,7 +241,7 @@ const glsl_type *glsl_symbol_table::get_type(const char *name) const class ast_type_specifier *glsl_symbol_table::get_type_ast(const char *name) { - char ast_name[strlen("#ast.") + strlen(name) + 1]; + char *ast_name=(char*)alloca(strlen("#ast.") + strlen(name) + 1); strcpy(ast_name, "#ast."); strcat(ast_name + strlen("#ast."), name); symbol_table_entry *entry = get_entry(ast_name); |