summaryrefslogtreecommitdiff
path: root/src/heretic/d_net.c
diff options
context:
space:
mode:
authorSimon Howard2014-03-29 21:24:03 -0400
committerSimon Howard2014-03-29 21:24:03 -0400
commit5f9b4368a2adad65dcc960a76c45d12059ca7214 (patch)
tree8b9096d02849b47fb4b445989704a8cde733583b /src/heretic/d_net.c
parent040ca1cfb5a3e1be7d05bcd90eaa4f01fb68437a (diff)
downloadchocolate-doom-5f9b4368a2adad65dcc960a76c45d12059ca7214.tar.gz
chocolate-doom-5f9b4368a2adad65dcc960a76c45d12059ca7214.tar.bz2
chocolate-doom-5f9b4368a2adad65dcc960a76c45d12059ca7214.zip
heretic: Eliminate use of unsafe string functions.
Eliminate use of strcpy, strcat, strncpy, and use the new safe alternatives.
Diffstat (limited to 'src/heretic/d_net.c')
-rw-r--r--src/heretic/d_net.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/heretic/d_net.c b/src/heretic/d_net.c
index e774eb03..f10302d0 100644
--- a/src/heretic/d_net.c
+++ b/src/heretic/d_net.c
@@ -29,11 +29,12 @@
#include "doomfeatures.h"
-#include "m_argv.h"
#include "i_system.h"
#include "i_timer.h"
#include "i_video.h"
#include "doomdef.h"
+#include "m_argv.h"
+#include "m_misc.h"
#include "w_checksum.h"
#include "deh_main.h"
@@ -60,7 +61,7 @@ static void PlayerQuitGame(player_t *player)
// The Heretic source code does this, which doesn't actually work.
// As a result, the exit message is never seen.
- strcpy(exitmsg, "PLAYER 1 LEFT THE GAME");
+ M_StringCopy(exitmsg, "PLAYER 1 LEFT THE GAME", sizeof(exitmsg));
exitmsg[7] += player_num;
players[consoleplayer].message = exitmsg;