Clean up Clang 15 sprintf() warnings in libcom and ca

This commit is contained in:
Andrew Johnson
2023-12-12 13:53:33 -06:00
parent 56dbc949ff
commit 5ecf7d18a8
7 changed files with 10 additions and 9 deletions

View File

@@ -73,7 +73,7 @@ void testMyThread()
int startPriority = 0;
for (int i = 0; i < ntasks; i++) {
char name[10];
sprintf(name, "t%d", i);
snprintf(name, sizeof(name), "t%d", i);
myThreads[i] = new myThread(i, name);
if (i == 0)
startPriority = myThreads[i]->thread.getPriority();