summaryrefslogtreecommitdiffstats
path: root/isisd
diff options
context:
space:
mode:
authorDavid Lamparter <equinox@opensourcerouting.org>2015-03-03 08:48:11 +0100
committerDonald Sharp <sharpd@cumulusnetworks.com>2016-05-30 03:08:04 +0200
commit8f2c16aab0388ea624ea67cf9a025a662ed9a84b (patch)
treef2cff306ac8fc7cbb31680ad25b6d1966ada24bb /isisd
parentzclient: Revert lib export of zclient_socket()/zclient_socket_un(). (diff)
downloadfrr-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 'isisd')
-rw-r--r--isisd/isis_adjacency.c3
-rw-r--r--isisd/isis_spf.c3
-rw-r--r--isisd/isisd.c4
3 files changed, 6 insertions, 4 deletions
diff --git a/isisd/isis_adjacency.c b/isisd/isis_adjacency.c
index bfd43d454..c7ab83ba0 100644
--- a/isisd/isis_adjacency.c
+++ b/isisd/isis_adjacency.c
@@ -390,7 +390,8 @@ isis_adj_print_vty (struct isis_adjacency *adj, struct vty *vty, char detail)
vty_out (vty, "%-13s", adj_state2string (adj->adj_state));
now = time (NULL);
if (adj->last_upd)
- vty_out (vty, "%-9lu", adj->last_upd + adj->hold_time - now);
+ vty_out (vty, "%-9llu",
+ (unsigned long long)adj->last_upd + adj->hold_time - now);
else
vty_out (vty, "- ");
vty_out (vty, "%-10s", snpa_print (adj->snpa));
diff --git a/isisd/isis_spf.c b/isisd/isis_spf.c
index 84c89bf61..d5ac85ef5 100644
--- a/isisd/isis_spf.c
+++ b/isisd/isis_spf.c
@@ -1472,7 +1472,8 @@ isis_spf_schedule6 (struct isis_area *area, int level)
if (isis->debugs & DEBUG_SPF_EVENTS)
zlog_debug ("ISIS-Spf (%s) L%d SPF scheduled %lld sec from now",
- area->area_tag, level, (long long)(area->min_spf_interval[level-1] - diff));
+ area->area_tag, level,
+ (long long)(area->min_spf_interval[level-1] - diff));
spftree->pending = 1;
diff --git a/isisd/isisd.c b/isisd/isisd.c
index c1f83e1d0..228d2bcb3 100644
--- a/isisd/isisd.c
+++ b/isisd/isisd.c
@@ -1364,8 +1364,8 @@ DEFUN (show_isis_summary,
vty_out_timestr(vty, spftree->last_run_timestamp);
vty_out (vty, "%s", VTY_NEWLINE);
- vty_out (vty, " last run duration : %ld msec%s",
- spftree->last_run_duration, VTY_NEWLINE);
+ vty_out (vty, " last run duration : %llu msec%s",
+ (unsigned long long)spftree->last_run_duration, VTY_NEWLINE);
vty_out (vty, " run count : %d%s",
spftree->runcount, VTY_NEWLINE);