From 9af3e9b30704fd687fa6b913cfa5bda2977ad71c Mon Sep 17 00:00:00 2001 From: Spoike Date: Wed, 19 May 2021 04:49:58 +0000 Subject: [PATCH] Fix small bug where the TF2.8 intro demo didn't play its music. git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5861 fc73d0e0-1445-4013-8a0c-d673dee63da5 --- engine/client/cl_parse.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/engine/client/cl_parse.c b/engine/client/cl_parse.c index 56bd54a0b..b51c95d9e 100644 --- a/engine/client/cl_parse.c +++ b/engine/client/cl_parse.c @@ -3913,7 +3913,7 @@ static void CLNQ_ParseServerData(void) //Doesn't change gamedir - use with caut Con_TPrintf ("Server sent too many model precaches\n"); return; } - strcpy (cl.model_name[nummodels], str); + Q_strncpyz(cl.model_name[nummodels], str, sizeof(cl.model_name[nummodels])); if (*str != '*' && strcmp(str, "null")) //not inline models! CL_CheckOrEnqueDownloadFile(str, NULL, ((nummodels==1)?DLLF_REQUIRED|DLLF_ALLOWWEB:0)); @@ -3959,7 +3959,8 @@ static void CLNQ_ParseServerData(void) //Doesn't change gamedir - use with caut Con_TPrintf ("Server sent too many sound precaches\n"); return; } - strcpy (cl.sound_name[numsounds], str); + Q_strncpyz(cl.sound_name[numsounds], str, sizeof(cl.sound_name[numsounds])); + cl.sound_precache[numsounds] = S_FindName(cl.sound_name[numsounds], true, false); Sound_CheckDownload(str); S_TouchSound (str);