diff options
author | David Lamparter <equinox@opensourcerouting.org> | 2015-03-03 08:48:11 +0100 |
---|---|---|
committer | Donald Sharp <sharpd@cumulusnetworks.com> | 2016-05-30 03:08:04 +0200 |
commit | 8f2c16aab0388ea624ea67cf9a025a662ed9a84b (patch) | |
tree | f2cff306ac8fc7cbb31680ad25b6d1966ada24bb /ospf6d/ospf6_spf.c | |
parent | zclient: Revert lib export of zclient_socket()/zclient_socket_un(). (diff) | |
download | frr-8f2c16aab0388ea624ea67cf9a025a662ed9a84b.tar.xz frr-8f2c16aab0388ea624ea67cf9a025a662ed9a84b.zip |
*: use long long to print time_t
Since we can't assume time_t to be long, int, or even long long, this
consistently uses %lld/long long (or %llu/unsigned long long in a few
cases) to print time_t/susecond_t values. This should fix a bunch of
warnings, on NetBSD in particular.
(Unfortunately, there seems to be no "PRId64" style printing macro for
time_t...)
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit ef008d2f8dc8f7160d8a3d24a15f2fad79ef3242)
Diffstat (limited to 'ospf6d/ospf6_spf.c')
-rw-r--r-- | ospf6d/ospf6_spf.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/ospf6d/ospf6_spf.c b/ospf6d/ospf6_spf.c index fda3bb5fb..7dc4801a8 100644 --- a/ospf6d/ospf6_spf.c +++ b/ospf6d/ospf6_spf.c @@ -651,11 +651,12 @@ ospf6_spf_calculation_thread (struct thread *t) ospf6_spf_reason_string(ospf6->spf_reason, rbuf, sizeof(rbuf)); if (IS_OSPF6_DEBUG_SPF (PROCESS) || IS_OSPF6_DEBUG_SPF (TIME)) - zlog_debug ("SPF runtime: %ld sec %ld usec", - runtime.tv_sec, runtime.tv_usec); + zlog_debug ("SPF runtime: %lld sec %lld usec", + (long long)runtime.tv_sec, (long long)runtime.tv_usec); - zlog_info("SPF processing: # Areas: %d, SPF runtime: %ld sec %ld usec, " - "Reason: %s\n", areas_processed, runtime.tv_sec, runtime.tv_usec, + zlog_info("SPF processing: # Areas: %d, SPF runtime: %lld sec %lld usec, " + "Reason: %s\n", areas_processed, + (long long)runtime.tv_sec, (long long)runtime.tv_usec, rbuf); ospf6->last_spf_reason = ospf6->spf_reason; ospf6_reset_spf_reason(ospf6); |