From 633b15caf3f616f7778ca153573097fcb7fdfad0 Mon Sep 17 00:00:00 2001 From: rubidium Date: Tue, 28 Oct 2008 16:04:41 +0000 Subject: (svn r14542) -Codechange: replace some sprintf with s[en]printf to make sure they will not overflow their buffers. --- src/music/os2_m.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/music') diff --git a/src/music/os2_m.cpp b/src/music/os2_m.cpp index 4461f003f..d4ceb23e8 100644 --- a/src/music/os2_m.cpp +++ b/src/music/os2_m.cpp @@ -27,7 +27,7 @@ static long CDECL MidiSendCommand(const char *cmd, ...) va_list va; char buf[512]; va_start(va, cmd); - vsprintf(buf, cmd, va); + vseprintf(buf, lastof(buf), cmd, va); va_end(va); return mciSendString(buf, NULL, 0, NULL, 0); } -- cgit v1.2.3-54-g00ecf