diff options
author | Stephen Hemminger <shemminger@vyatta.com> | 2009-12-10 15:52:33 +0300 |
---|---|---|
committer | Denis Ovsienko <infrastation@yandex.ru> | 2009-12-10 15:52:33 +0300 |
commit | 5eb9d11bf6bbe99ce47f929a14ac03351f21fe27 (patch) | |
tree | 79e72d2cace42a33b7c742c10319808b7837a36b /ripngd/ripngd.c | |
parent | ab0f61552622084a13ede59adefc4c54b5513d7b (diff) |
ripngd: compiler warnings cleanup
* ripngd/ripng_interface.c
* ripng_check_max_mtu(): unused, sayonara
* ripng_interface_down(): cast flag arguments to logging function
* ripng_interface_add(): idem
* ripng_interface_delete(): idem
* ripngd/ripngd.c
* ripng_recv_packet(): avoid aliasing warning dereferencing pointer
Diffstat (limited to 'ripngd/ripngd.c')
-rw-r--r-- | ripngd/ripngd.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/ripngd/ripngd.c b/ripngd/ripngd.c index 9deac032..6e32d83c 100644 --- a/ripngd/ripngd.c +++ b/ripngd/ripngd.c @@ -272,7 +272,10 @@ ripng_recv_packet (int sock, u_char *buf, int bufsize, /* Incoming packet's multicast hop limit. */ if (cmsgptr->cmsg_level == IPPROTO_IPV6 && cmsgptr->cmsg_type == IPV6_HOPLIMIT) - *hoplimit = *((int *) CMSG_DATA (cmsgptr)); + { + int *phoplimit = (int *) CMSG_DATA (cmsgptr); + *hoplimit = *phoplimit; + } } /* Hoplimit check shold be done when destination address is |