From 5b4610fa59fa393f07f962f04189b4032b681c7b Mon Sep 17 00:00:00 2001 From: Mark Stapp Date: Tue, 19 Sep 2023 16:24:07 -0400 Subject: [PATCH] tests: replace ctime with ctime_r Replace ctime with ctime_r in bgp test. Signed-off-by: Mark Stapp --- tests/bgpd/test_mpath.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/bgpd/test_mpath.c b/tests/bgpd/test_mpath.c index bc2c1e8a44..ebbe3ac3e2 100644 --- a/tests/bgpd/test_mpath.c +++ b/tests/bgpd/test_mpath.c @@ -467,9 +467,10 @@ int main(void) { int pass_count, fail_count; time_t cur_time; + char buf[32]; time(&cur_time); - printf("BGP Multipath Tests Run at %s", ctime(&cur_time)); + printf("BGP Multipath Tests Run at %s", ctime_r(&cur_time, buf)); if (global_test_init() != 0) { printf("Global init failed. Terminating.\n"); exit(1); -- 2.39.5