aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/session/application_worker.c
diff options
context:
space:
mode:
authorDave Barach <dbarach@u1804>2020-04-04 10:05:48 -0400
committerDave Barach <dave@barachs.net>2020-04-04 10:14:06 -0400
commit3e07a4a1e843267892dc291a833d93bd70597011 (patch)
tree5f8aa93c936f8acea9b6389c5fe1f75d770e4ae7 /src/vnet/session/application_worker.c
parent3102c382f0c470e95b2ba7c399a2418e2dc1542a (diff)
misc: sprintf be gone
Along with related static analysis warnings... Type: fix Ticket: VPP-1837 Signed-off-by: Dave Barach <dave@barachs.net> Change-Id: I2c6949c7a2250b8f76a63508c7c210daecfe0f91
Diffstat (limited to 'src/vnet/session/application_worker.c')
-rw-r--r--src/vnet/session/application_worker.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/vnet/session/application_worker.c b/src/vnet/session/application_worker.c
index c17f43e90d1..a3dc32a5b1e 100644
--- a/src/vnet/session/application_worker.c
+++ b/src/vnet/session/application_worker.c
@@ -699,10 +699,11 @@ format_app_worker_listener (u8 * s, va_list * args)
if (verbose)
{
- char buf[32];
- sprintf (buf, "%u(%u)", app_wrk->wrk_map_index, app_wrk->wrk_index);
- s = format (s, "%-40s%-25s%=10s%-15u%-15u%-10u", str, app_name,
+ u8 *buf;
+ buf = format (0, "%u(%u)", app_wrk->wrk_map_index, app_wrk->wrk_index);
+ s = format (s, "%-40s%-25s%=10v%-15u%-15u%-10u", str, app_name,
buf, app_wrk->api_client_index, handle, sm_index);
+ vec_free (buf);
}
else
s = format (s, "%-40s%-25s%=10u", str, app_name, app_wrk->wrk_map_index);