summaryrefslogtreecommitdiff
path: root/src/strife/st_stuff.c
diff options
context:
space:
mode:
authorSimon Howard2014-03-30 19:08:27 -0400
committerSimon Howard2014-03-30 19:08:27 -0400
commit2ea8fd11ec5da77ba66b24c0c2cbee892e803904 (patch)
treeeed48a3b6ce007c54671099c33a041a081609681 /src/strife/st_stuff.c
parent01ae851bf998330a9ca95467e238c507aa55cae1 (diff)
downloadchocolate-doom-2ea8fd11ec5da77ba66b24c0c2cbee892e803904.tar.gz
chocolate-doom-2ea8fd11ec5da77ba66b24c0c2cbee892e803904.tar.bz2
chocolate-doom-2ea8fd11ec5da77ba66b24c0c2cbee892e803904.zip
strife: Eliminate use of sprintf().
Use snprintf() in place of sprintf(). This is part of fixing #371.
Diffstat (limited to 'src/strife/st_stuff.c')
-rw-r--r--src/strife/st_stuff.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/strife/st_stuff.c b/src/strife/st_stuff.c
index 290edc5c..34682093 100644
--- a/src/strife/st_stuff.c
+++ b/src/strife/st_stuff.c
@@ -663,7 +663,8 @@ boolean ST_Responder(event_t* ev)
{
// [STRIFE] 'GPS' for player position
static char buf[ST_MSGWIDTH];
- sprintf(buf, "ang=0x%x;x,y=(0x%x,0x%x)",
+ snprintf(buf, sizeof(buf),
+ "ang=0x%x;x,y=(0x%x,0x%x)",
players[consoleplayer].mo->angle,
players[consoleplayer].mo->x,
players[consoleplayer].mo->y);