From 37b9c311184c21dda3da165c18933b707d2a227b Mon Sep 17 00:00:00 2001 From: rubidium Date: Mon, 3 Jan 2011 12:04:53 +0000 Subject: (svn r21702) -Fix: make sure the colour argument of echoc is properly validated to be a text colour --- src/console_cmds.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/console_cmds.cpp') diff --git a/src/console_cmds.cpp b/src/console_cmds.cpp index 85c3a6d98..4012c1c8a 100644 --- a/src/console_cmds.cpp +++ b/src/console_cmds.cpp @@ -958,7 +958,7 @@ DEF_CONSOLE_CMD(ConEchoC) } if (argc < 3) return false; - IConsolePrint((TextColour)atoi(argv[1]), argv[2]); + IConsolePrint((TextColour)Clamp(atoi(argv[1]), TC_BEGIN, TC_END - 1), argv[2]); return true; } -- cgit v1.2.3-54-g00ecf