X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?p=o-du%2Fphy.git;a=blobdiff_plain;f=fhi_lib%2Flib%2Fsrc%2Fxran_sync_api.c;h=873c2c1a8e6b7162b7d586c5fd23a3cac54c0260;hp=5b1295f2299c3a4728903de32324620d1e802ede;hb=afaa7b205ebe18aaa4ddb2cea457c647df2a3444;hpb=bdbd414e8038630c154ee3c6b8bc9b3aeb954be6 diff --git a/fhi_lib/lib/src/xran_sync_api.c b/fhi_lib/lib/src/xran_sync_api.c index 5b1295f..873c2c1 100644 --- a/fhi_lib/lib/src/xran_sync_api.c +++ b/fhi_lib/lib/src/xran_sync_api.c @@ -71,7 +71,7 @@ static int is_process_running(char *pname) long pid = atol(entry->d_name); if (0 == pid) continue; - sprintf(full_path, "%s/%ld/%s", PROC_DIR, pid, COMM_FILE); + snprintf(full_path, sizeof(full_path), "%s/%ld/%s", PROC_DIR, pid, COMM_FILE); FILE *proc_name_file = fopen(full_path, "r"); if (NULL == proc_name_file) continue;