1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-06 06:32:56 +01:00

Fix garbage in buffer

This commit is contained in:
Hielke Morsink
2017-12-29 01:59:07 +01:00
committed by Richard Jenkins
parent 50f16b6600
commit d2f732bbb6

View File

@@ -102,7 +102,7 @@ static sint32 _maxInputLength;
void window_text_input_open(rct_window* call_w, rct_widgetindex call_widget, rct_string_id title, rct_string_id description, rct_string_id existing_text, uintptr_t existing_args, sint32 maxLength)
{
// Get the raw string
utf8 buffer[Util::CountOf(text_input)];
utf8 buffer[Util::CountOf(text_input)]{};
if (existing_text != STR_NONE)
format_string(buffer, maxLength, existing_text, &existing_args);