[PATCH 02/10] top/task1.c: Fix sprintf() buffer overflow

Joel Sherrill joel at rtems.org
Wed Jun 21 17:52:09 UTC 2017


---
 testsuites/libtests/top/task1.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/testsuites/libtests/top/task1.c b/testsuites/libtests/top/task1.c
index fc81f51..c9e62df 100644
--- a/testsuites/libtests/top/task1.c
+++ b/testsuites/libtests/top/task1.c
@@ -28,7 +28,7 @@ static void create_and_start( uint32_t i )
 {
   rtems_status_code status;
   char              str[30];
-  char              name[5];
+  char              name[6];
 
   sprintf(name, "TA%02" PRId32 " ", i);
 
-- 
1.8.3.1




More information about the devel mailing list