Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Try to fix #8852 (SimGrid won't compile on Ubuntu 9.10) by betterly checking my argum...
[simgrid.git] / src / xbt / cunit.c
index 15d6afa..57a988c 100644 (file)
@@ -284,7 +284,7 @@ static int xbt_test_suite_run(xbt_test_suite_t suite)
     sprintf(suite_title + 40 - (suite_len + 4) / 2, "[ %s ]", suite->title);
     suite_title[40 + (suite_len + 5) / 2] = '=';
     if (!suite->enabled)
     sprintf(suite_title + 40 - (suite_len + 4) / 2, "[ %s ]", suite->title);
     suite_title[40 + (suite_len + 5) / 2] = '=';
     if (!suite->enabled)
-      sprintf(suite_title + 70, " DISABLED ");
+      snprintf(suite_title + 70, 11, " DISABLED ");
     fprintf(stderr, "\n%s\n", suite_title);
   }
 
     fprintf(stderr, "\n%s\n", suite_title);
   }