Replace final sprintf() with snprintf() in psa_ff_server.c

Signed-off-by: Tom Cosgrove <tom.cosgrove@arm.com>
This commit is contained in:
Tom Cosgrove 2024-05-27 10:08:34 +03:00
parent c7569a8c4b
commit b7e5f31e2a

View File

@ -638,7 +638,7 @@ void __init_psasim(const char **array,
if (strncmp(array[i], "", 1) != 0) {
INFO("Setting up %s", array[i]);
memset(queue_path, 0, sizeof(queue_path));
sprintf(queue_path, "%s%s", TMP_FILE_BASE_PATH, array[i]);
snprintf(queue_path, sizeof(queue_path), "%s%s", TMP_FILE_BASE_PATH, array[i]);
/* Create file if doesn't exist */
fp = fopen(queue_path, "ab+");