diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2021-02-14 17:34:24 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-14 17:34:24 +0100 |
commit | 4302b506d266037535413890259acb2b20ae3c07 (patch) | |
tree | c3a264eaf7885649251c47db0ea88b60b00861c7 | |
parent | 4a41367949bbb3086599fe845ff2d8e17f585931 (diff) | |
parent | 7d451c0040ae1c47dad6ecd58905e77bda239e7d (diff) |
Merge pull request #46021 from kleonc/visualshader_index_check
VisualShader::_input_type_changed Fix index out of bounds crash.
-rw-r--r-- | scene/resources/visual_shader.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/scene/resources/visual_shader.cpp b/scene/resources/visual_shader.cpp index 219cd84aa0..438e130cf4 100644 --- a/scene/resources/visual_shader.cpp +++ b/scene/resources/visual_shader.cpp @@ -1597,6 +1597,7 @@ void VisualShader::_queue_update() { } void VisualShader::_input_type_changed(Type p_type, int p_id) { + ERR_FAIL_INDEX(p_type, TYPE_MAX); //erase connections using this input, as type changed Graph *g = &graph[p_type]; |