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 /watchquagga | |
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 'watchquagga')
-rw-r--r-- | watchquagga/watchquagga.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/watchquagga/watchquagga.c b/watchquagga/watchquagga.c index 5cb224a45..e882653e3 100644 --- a/watchquagga/watchquagga.c +++ b/watchquagga/watchquagga.c @@ -389,7 +389,7 @@ restart_kill(struct thread *t_kill) time_elapsed(&delay,&restart->time); zlog_warn("Warning: %s %s child process %d still running after " "%ld seconds, sending signal %d", - restart->what,restart->name,(int)restart->pid,delay.tv_sec, + restart->what,restart->name,(int)restart->pid, (long)delay.tv_sec, (restart->kills ? SIGKILL : SIGTERM)); kill(-restart->pid,(restart->kills ? SIGKILL : SIGTERM)); restart->kills++; @@ -662,15 +662,17 @@ handle_read(struct thread *t_read) { dmn->state = DAEMON_UP; zlog_warn("%s state -> up : echo response received after %ld.%06ld " - "seconds", dmn->name,delay.tv_sec,delay.tv_usec); + "seconds", dmn->name, + (long)delay.tv_sec, (long)delay.tv_usec); } else zlog_warn("%s: slow echo response finally received after %ld.%06ld " - "seconds", dmn->name,delay.tv_sec,delay.tv_usec); + "seconds", dmn->name, + (long)delay.tv_sec, (long)delay.tv_usec); } else if (gs.loglevel > LOG_DEBUG+1) zlog_debug("%s: echo response received after %ld.%06ld seconds", - dmn->name,delay.tv_sec,delay.tv_usec); + dmn->name, (long)delay.tv_sec, (long)delay.tv_usec); SET_READ_HANDLER(dmn); if (dmn->t_wakeup) |