From 6cc3bed60aa80c83a4dd6f9c22268572325a03f8 Mon Sep 17 00:00:00 2001 From: Alibek Omarov Date: Wed, 9 Jul 2025 19:04:59 +0500 Subject: [PATCH] engine: client: console: fix uninitialized variable --- engine/client/console.c | 1 + 1 file changed, 1 insertion(+) diff --git a/engine/client/console.c b/engine/client/console.c index 6c7bf002..5f33e61a 100644 --- a/engine/client/console.c +++ b/engine/client/console.c @@ -1276,6 +1276,7 @@ static void Field_DrawInputLine( int x, int y, const field_t *edit ) const int drawLen = bound( 0, edit->widthInChars, sizeof( str )); const int cursorCharPos = bound( 0, edit->cursor - prestep, sizeof( str )); + str[0] = 0; Q_strncpy( str, edit->buffer + prestep, drawLen ); // draw it