summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/message.cc
diff options
context:
space:
mode:
authorAdam Borowski <kilobyte@angband.pl>2009-12-17 12:48:02 +0100
committerAdam Borowski <kilobyte@angband.pl>2009-12-17 12:48:02 +0100
commit1ab177757bec9eb28482785f75fd8a4fb8a1313c (patch)
tree4b1c8babcca442dc8b91a624b842bc5f30013747 /crawl-ref/source/message.cc
parentc266f14414471d5252130c70bafa0c60f85a265c (diff)
downloadcrawl-ref-1ab177757bec9eb28482785f75fd8a4fb8a1313c.tar.gz
crawl-ref-1ab177757bec9eb28482785f75fd8a4fb8a1313c.zip
Replace static snprintf() with make_sprintf() where the result is immediately cast
to std::string.
Diffstat (limited to 'crawl-ref/source/message.cc')
-rw-r--r--crawl-ref/source/message.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/crawl-ref/source/message.cc b/crawl-ref/source/message.cc
index d0fc3e7e9f..c2fce04242 100644
--- a/crawl-ref/source/message.cc
+++ b/crawl-ref/source/message.cc
@@ -413,6 +413,7 @@ int channel_to_colour( msg_channel_type channel, int param )
static void do_message_print( msg_channel_type channel, int param,
const char *format, va_list argp )
{
+ // Is this limit intentional?
char buff[200];
vsnprintf( buff, sizeof( buff ), format, argp );
buff[199] = 0;