mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-24 19:40:10 +01:00
The get_variable_being_redeclared() function can free 'var' because a re-declaration of an unsized array variable can establish the size, so we set the array type to the 'earlier' declaration and free 'var' as it is not needed anymore. However, the same 'var' is referenced later in ast_declarator_list::hir(). This patch fixes it by picking the ir_variable_mode from the proper ir_variable. This error was detected by Address Sanitizer. Signed-off-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com> Suggested-by: Ian Romanick <ian.d.romanick@intel.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=99677 Cc: "17.0" <mesa-stable@lists.freedesktop.org> Cc: "13.0" <mesa-stable@lists.freedesktop.org> |
||
|---|---|---|
| .. | ||
| glsl | ||
| nir | ||
| spirv | ||
| .gitignore | ||
| Android.glsl.gen.mk | ||
| Android.glsl.mk | ||
| Android.mk | ||
| Android.nir.gen.mk | ||
| Android.nir.mk | ||
| builtin_type_macros.h | ||
| glsl_types.cpp | ||
| glsl_types.h | ||
| Makefile.am | ||
| Makefile.glsl.am | ||
| Makefile.nir.am | ||
| Makefile.sources | ||
| nir_types.cpp | ||
| nir_types.h | ||
| SConscript | ||
| SConscript.glsl | ||
| SConscript.nir | ||
| shader_enums.c | ||
| shader_enums.h | ||
| shader_info.h | ||