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

@@ -244,7 +244,7 @@ MAIN(epicsEventTest)
name = (char **)calloc(nthreads, sizeof(char *));
for(int i = 0; i < nthreads; i++) {
name[i] = (char *)calloc(16, sizeof(char));
sprintf(name[i],"producer %d",i);
snprintf(name[i], 16, "producer %d",i);
id[i] = epicsThreadCreate(name[i], 40, stackSize, producer, pinfo);
epicsThreadSleep(0.1);
}