diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2020-04-02 13:07:55 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-02 13:07:55 +0200 |
commit | 5f11e1557156617366d2c316a97716172103980d (patch) | |
tree | 288d8275067df46a8fc58e99184c74955de39bd8 /scene/resources | |
parent | 7341a8fe1df65dc4d36aa49938575b6099764c0a (diff) | |
parent | 359bebd8c08a626e64ade1ac45c3c925352bd8a4 (diff) |
Merge pull request #37504 from qarmin/out_of_bound_cursor
Fix array out of bounds access caused by uninitialised variables
Diffstat (limited to 'scene/resources')
-rw-r--r-- | scene/resources/animation.h | 5 | ||||
-rw-r--r-- | scene/resources/dynamic_font.cpp | 1 |
2 files changed, 5 insertions, 1 deletions
diff --git a/scene/resources/animation.h b/scene/resources/animation.h index 36d5df52df..e4e5177a8c 100644 --- a/scene/resources/animation.h +++ b/scene/resources/animation.h @@ -84,7 +84,10 @@ private: float transition; float time; // time in secs - Key() { transition = 1; } + Key() { + transition = 1; + time = 0; + } }; // transform key holds either Vector3 or Quaternion diff --git a/scene/resources/dynamic_font.cpp b/scene/resources/dynamic_font.cpp index 107f07ec7d..108b1d0d5a 100644 --- a/scene/resources/dynamic_font.cpp +++ b/scene/resources/dynamic_font.cpp @@ -997,6 +997,7 @@ SelfList<DynamicFont>::List *DynamicFont::dynamic_fonts = NULL; DynamicFont::DynamicFont() : font_list(this) { + valid = false; cache_id.size = 16; outline_cache_id.size = 16; spacing_top = 0; |