From: cloudwalk Date: Sat, 27 Jun 2020 02:27:20 +0000 (+0000) Subject: In Nicks_CompleteCountPossible, use MAX_SCOREBOARDNAME for buffer size X-Git-Url: http://git.xonotic.org/?p=xonotic%2Fdarkplaces.git;a=commitdiff_plain;h=6afcda4c96b644d858bf56252307f7e3bf5ee416;ds=sidebyside In Nicks_CompleteCountPossible, use MAX_SCOREBOARDNAME for buffer size Prevents potential buffer overflow. Fix by terencehill git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12738 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/console.c b/console.c index 72563d25..637599c0 100644 --- a/console.c +++ b/console.c @@ -2427,7 +2427,7 @@ static int Nicks_strncasecmp(char *a, char *b, unsigned int a_len) */ static int Nicks_CompleteCountPossible(char *line, int pos, char *s, qboolean isCon) { - char name[128]; + char name[MAX_SCOREBOARDNAME]; int i, p; int match; int spos;