diff options
author | David Lamparter <equinox@opensourcerouting.org> | 2015-03-04 06:37:20 +0100 |
---|---|---|
committer | David Lamparter <equinox@opensourcerouting.org> | 2015-04-21 10:18:38 +0200 |
commit | c7879ea62fb38999a86ca9cbabbdeca18785e135 (patch) | |
tree | a341dc46185e3139000334ff6733b2ffdec8134c | |
parent | a2c7f4bd869bd232eb12896ff65a510d6716d2b9 (diff) | |
download | quagga-c7879ea62fb38999a86ca9cbabbdeca18785e135.tar.bz2 quagga-c7879ea62fb38999a86ca9cbabbdeca18785e135.tar.xz |
pimd: cast ioctl values when printing them
ioctl values might be int or long, cast them to unsigned long for
consistent printing. (They're long on FreeBSD, but were printed with
%d.)
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
-rw-r--r-- | pimd/pim_cmd.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/pimd/pim_cmd.c b/pimd/pim_cmd.c index 6b2ac664..13812cd8 100644 --- a/pimd/pim_cmd.c +++ b/pimd/pim_cmd.c @@ -2031,8 +2031,8 @@ static void show_multicast_interfaces(struct vty *vty) if (ioctl(qpim_mroute_socket_fd, SIOCGETVIFCNT, &vreq)) { int e = errno; vty_out(vty, - "ioctl(SIOCGETVIFCNT=%d) failure for interface %s vif_index=%d: errno=%d: %s%s", - SIOCGETVIFCNT, + "ioctl(SIOCGETVIFCNT=%lu) failure for interface %s vif_index=%d: errno=%d: %s%s", + (unsigned long)SIOCGETVIFCNT, ifp->name, pim_ifp->mroute_vif_index, e, @@ -2225,8 +2225,8 @@ static void show_mroute_count(struct vty *vty) if (ioctl(qpim_mroute_socket_fd, SIOCGETSGCNT, &sgreq)) { int e = errno; vty_out(vty, - "ioctl(SIOCGETSGCNT=%d) failure for (S,G)=(%s,%s): errno=%d: %s%s", - SIOCGETSGCNT, + "ioctl(SIOCGETSGCNT=%lu) failure for (S,G)=(%s,%s): errno=%d: %s%s", + (unsigned long)SIOCGETSGCNT, source_str, group_str, e, |