diff --git a/distribution/changelog.txt b/distribution/changelog.txt index ab7910cfae..d507fe8003 100644 --- a/distribution/changelog.txt +++ b/distribution/changelog.txt @@ -32,6 +32,7 @@ - Fix: [#20484] Console caret not properly updated when using command history. - Fix: [#20543] Crash using show segments height from debug paint options. - Fix: [#20607] Infinite loop when renaming rides with default names longer than 32 bytes. +- Fix: [#20642] Track list is sometimes empty due to uninitialized data for the filter string. 0.4.5 (2023-05-08) ------------------------------------------------------------------------ diff --git a/src/openrct2-ui/windows/TrackList.cpp b/src/openrct2-ui/windows/TrackList.cpp index 1f52565fa7..79c094436c 100644 --- a/src/openrct2-ui/windows/TrackList.cpp +++ b/src/openrct2-ui/windows/TrackList.cpp @@ -73,7 +73,7 @@ class TrackListWindow final : public Window { private: std::vector _trackDesigns; - utf8 _filterString[USER_STRING_MAX_LENGTH]; + utf8 _filterString[USER_STRING_MAX_LENGTH]{}; std::vector _filteredTrackIds; uint16_t _loadedTrackDesignIndex; std::unique_ptr _loadedTrackDesign;