diff options
author | Stephen Hemminger <shemminger@vyatta.com> | 2009-12-10 12:22:44 +0100 |
---|---|---|
committer | Denis Ovsienko <infrastation@yandex.ru> | 2009-12-10 12:22:44 +0100 |
commit | ab0f61552622084a13ede59adefc4c54b5513d7b (patch) | |
tree | d85ca70e55f064fd3a24072cf0f9a5fbbcdd5181 /zebra/irdp_packet.c | |
parent | bgpd: compile warnings cleanup (diff) | |
download | frr-ab0f61552622084a13ede59adefc4c54b5513d7b.tar.xz frr-ab0f61552622084a13ede59adefc4c54b5513d7b.zip |
zebra: deal with irdp compile warnings
* zebra/irdp.h
* irdp_send_thread(): move prototype to common header file
* irdp_advert_off(): idem
* process_solicit(): idem
* irdp_read_raw(): idem
* send_packet(): idem
* zebra/irdp_interface.c
* inet_2a(): move function to where it is used
* in_cksum(): lib/checksum.h already provides prototype
* irdp_send_thread(): prototype moved away
* inet_2a(): idem
* irdp_advert_off(): idem
* b1, b2, b3, b4: get rid of global buffers for inet_2a()
* if_group(): add local buffer for inet_2a()
* if_add_group(): idem
* if_drop_group(): idem
* irdp_config_write(): idem
* Adv_new(): make static
* zebra/irdp_main.c
* irdp_read_raw(): prototype moved away
* send_packet(): idem
* in_cksum(): lib/checksum.h already provides prototype
* inet_2a(): function moved to irdp_interface.c
* zebra/irdp_packet.c
* b1, b2, b3, b4: get rid of global buffers for inet_2a()
* in_cksum(): lib/checksum.h already provides prototype
* process_solicit(): prototype moved away
* irdp_read_raw(): fix uninitialized variable
Diffstat (limited to 'zebra/irdp_packet.c')
-rw-r--r-- | zebra/irdp_packet.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/zebra/irdp_packet.c b/zebra/irdp_packet.c index 600383728..28dc171ed 100644 --- a/zebra/irdp_packet.c +++ b/zebra/irdp_packet.c @@ -59,6 +59,7 @@ #include "zebra/irdp.h" #include <netinet/ip_icmp.h> #include "if.h" +#include "checksum.h" #include "sockunion.h" #include "log.h" #include "sockopt.h" @@ -67,12 +68,9 @@ /* GLOBAL VARS */ int irdp_sock = -1; -char b1[16], b2[16], b3[16], b4[16]; /* For inet_2a */ extern struct zebra_t zebrad; extern struct thread *t_irdp_raw; -int in_cksum (void *ptr, int nbytes); -void process_solicit (struct interface *ifp); static void parse_irdp_packet(char *p, @@ -231,7 +229,7 @@ int irdp_read_raw(struct thread *r) struct zebra_if *zi; struct irdp_interface *irdp; char buf[IRDP_RX_BUF]; - int ret, ifindex; + int ret, ifindex = 0; int irdp_sock = THREAD_FD (r); t_irdp_raw = thread_add_read (zebrad.master, irdp_read_raw, NULL, irdp_sock); |