From f25e5e94f7cd529fe57e1cbe94a9aafce94aaddf Mon Sep 17 00:00:00 2001 From: Cristian Maglie Date: Thu, 6 Jun 2013 20:04:43 +0200 Subject: Fixed buffer overflow on String class (Paul Stoffregen) --- cores/robot/WString.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'cores/robot') diff --git a/cores/robot/WString.cpp b/cores/robot/WString.cpp index ace128d..8c85cc5 100644 --- a/cores/robot/WString.cpp +++ b/cores/robot/WString.cpp @@ -296,14 +296,14 @@ unsigned char String::concat(unsigned char num) unsigned char String::concat(int num) { - char buf[7]; + char buf[12]; itoa(num, buf, 10); return concat(buf, strlen(buf)); } unsigned char String::concat(unsigned int num) { - char buf[6]; + char buf[11]; utoa(num, buf, 10); return concat(buf, strlen(buf)); } -- cgit v1.2.3-18-g5258