forked from Mirror/frr
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>
This commit is contained in:
parent
59e96cda41
commit
1cb17fc701
|
@ -2031,8 +2031,8 @@ static void show_multicast_interfaces(struct vty *vty)
|
||||||
if (ioctl(qpim_mroute_socket_fd, SIOCGETVIFCNT, &vreq)) {
|
if (ioctl(qpim_mroute_socket_fd, SIOCGETVIFCNT, &vreq)) {
|
||||||
int e = errno;
|
int e = errno;
|
||||||
vty_out(vty,
|
vty_out(vty,
|
||||||
"ioctl(SIOCGETVIFCNT=%d) failure for interface %s vif_index=%d: errno=%d: %s%s",
|
"ioctl(SIOCGETVIFCNT=%lu) failure for interface %s vif_index=%d: errno=%d: %s%s",
|
||||||
SIOCGETVIFCNT,
|
(unsigned long)SIOCGETVIFCNT,
|
||||||
ifp->name,
|
ifp->name,
|
||||||
pim_ifp->mroute_vif_index,
|
pim_ifp->mroute_vif_index,
|
||||||
e,
|
e,
|
||||||
|
@ -2225,8 +2225,8 @@ static void show_mroute_count(struct vty *vty)
|
||||||
if (ioctl(qpim_mroute_socket_fd, SIOCGETSGCNT, &sgreq)) {
|
if (ioctl(qpim_mroute_socket_fd, SIOCGETSGCNT, &sgreq)) {
|
||||||
int e = errno;
|
int e = errno;
|
||||||
vty_out(vty,
|
vty_out(vty,
|
||||||
"ioctl(SIOCGETSGCNT=%d) failure for (S,G)=(%s,%s): errno=%d: %s%s",
|
"ioctl(SIOCGETSGCNT=%lu) failure for (S,G)=(%s,%s): errno=%d: %s%s",
|
||||||
SIOCGETSGCNT,
|
(unsigned long)SIOCGETSGCNT,
|
||||||
source_str,
|
source_str,
|
||||||
group_str,
|
group_str,
|
||||||
e,
|
e,
|
||||||
|
|
Loading…
Reference in a new issue