summaryrefslogtreecommitdiff
path: root/src/heretic/ct_chat.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/heretic/ct_chat.c')
-rw-r--r--src/heretic/ct_chat.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/heretic/ct_chat.c b/src/heretic/ct_chat.c
index 958d1fff..8059b74d 100644
--- a/src/heretic/ct_chat.c
+++ b/src/heretic/ct_chat.c
@@ -301,7 +301,9 @@ void CT_Ticker(void)
CT_AddChar(i, 0); // set the end of message character
if (numplayers > 2)
{
- strcpy(plr_lastmsg[i], DEH_String(CT_FromPlrText[i]));
+ strncpy(plr_lastmsg[i], DEH_String(CT_FromPlrText[i]),
+ MESSAGESIZE + 9);
+ plr_lastmsg[i][MESSAGESIZE + 8] = '\0';
strcat(plr_lastmsg[i], chat_msg[i]);
}
else