summaryrefslogtreecommitdiff
path: root/src/doom/s_sound.c
diff options
context:
space:
mode:
authorSimon Howard2014-03-30 18:21:42 -0400
committerSimon Howard2014-03-30 18:21:42 -0400
commit4465be140a27e47aa8bed15be4e58064297c7d94 (patch)
treef27954337910f277d7883feab70e6b2a1fc421b6 /src/doom/s_sound.c
parente56c9c948df1ad0e2ff2b64d8593caefbf98fd11 (diff)
downloadchocolate-doom-4465be140a27e47aa8bed15be4e58064297c7d94.tar.gz
chocolate-doom-4465be140a27e47aa8bed15be4e58064297c7d94.tar.bz2
chocolate-doom-4465be140a27e47aa8bed15be4e58064297c7d94.zip
doom: Eliminate use of sprintf().
Use snprintf() or other functions in place of sprintf(). This is part of fixing #371.
Diffstat (limited to 'src/doom/s_sound.c')
-rw-r--r--src/doom/s_sound.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/doom/s_sound.c b/src/doom/s_sound.c
index 7b000e94..4e81b016 100644
--- a/src/doom/s_sound.c
+++ b/src/doom/s_sound.c
@@ -638,7 +638,7 @@ void S_ChangeMusic(int musicnum, int looping)
// get lumpnum if neccessary
if (!music->lumpnum)
{
- sprintf(namebuf, "d_%s", DEH_String(music->name));
+ snprintf(namebuf, sizeof(namebuf), "d_%s", DEH_String(music->name));
music->lumpnum = W_GetNumForName(namebuf);
}