diff options
author | paul <paul> | 2004-10-10 12:54:58 +0000 |
---|---|---|
committer | paul <paul> | 2004-10-10 12:54:58 +0000 |
commit | 0c083ee9d870bf02a36563ae1807f3894ac24219 (patch) | |
tree | 04315c9103131381b9ca5e1d576e27a1f22d0da1 /ospf6d/ospf6_lsa.c | |
parent | 9035efaa924c69f4f4fcb1049c7dc4f43b9da980 (diff) | |
download | quagga-0c083ee9d870bf02a36563ae1807f3894ac24219.tar.bz2 quagga-0c083ee9d870bf02a36563ae1807f3894ac24219.tar.xz |
2004-10-10 Paul Jakma <paul@dishone.st>
* ospf6_route.c: Add const qualifier to various char arrays of
constants. signed/unsigned fixes.
(ospf6_linkstate_table_show) argv is const
* ospf6_snmp.c: listnode typedef is dead.
(ospf6_snmp_init) Take struct thread_master arg, needed for
smux_init.
* ospf6_snmp.h: update ospf6_snmp_init declaration.
* ospf6d.c: (ospf6_init) add const qualifier to sargv, pass master
to ospf_snmp6_init.
* ospf6_asbr.c: const char update.
* ospf6_interface.c: ditto, plus signed/unsigned fixes.
(ipv6_ospf6_cost) Check whether cost fits in u_int32_t and use
strtoul.
* ospf6_intra.c: const char update. Parenthesise expression.
* ospf6_lsa.c: signed/unsigned and const char updates.
* ospf6_proto.c: ditto.
* ospf6_message.c: ditto.
* ospf6_lsdb.c: signed/unsigned update.
* ospf6_main.c: const char update.
* ospf6_neighbor.c: ditto.
* ospf6_spf.c: ditto.
* ospf6_top.c: ditto.
Diffstat (limited to 'ospf6d/ospf6_lsa.c')
-rw-r--r-- | ospf6d/ospf6_lsa.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/ospf6d/ospf6_lsa.c b/ospf6d/ospf6_lsa.c index da732798..d6356c72 100644 --- a/ospf6d/ospf6_lsa.c +++ b/ospf6d/ospf6_lsa.c @@ -90,7 +90,7 @@ struct ospf6_lsa_handler * ospf6_get_lsa_handler (u_int16_t type) { struct ospf6_lsa_handler *handler = NULL; - int index = ntohs (type) & OSPF6_LSTYPE_FCODE_MASK; + unsigned int index = ntohs (type) & OSPF6_LSTYPE_FCODE_MASK; if (index >= vector_max (ospf6_lsa_handler_vector)) handler = &unknown_handler; @@ -100,7 +100,7 @@ ospf6_get_lsa_handler (u_int16_t type) return handler; } -char * +const char * ospf6_lstype_name (u_int16_t type) { static char buf[8]; @@ -711,7 +711,8 @@ char * ospf6_lsa_handler_name (struct ospf6_lsa_handler *h) { static char buf[64]; - int i, size = strlen (h->name); + unsigned int i; + unsigned int size = strlen (h->name); if (h->name == "Unknown" && h->type != OSPF6_LSTYPE_UNKNOWN) @@ -740,7 +741,7 @@ DEFUN (debug_ospf6_lsa_type, "Specify LS type as Hexadecimal\n" ) { - int i; + unsigned int i; struct ospf6_lsa_handler *handler = NULL; unsigned long val; char *endptr = NULL; @@ -808,7 +809,7 @@ DEFUN (no_debug_ospf6_lsa_type, "Specify LS type as Hexadecimal\n" ) { - int i; + u_int i; struct ospf6_lsa_handler *handler = NULL; unsigned long val; char *endptr = NULL; @@ -868,7 +869,7 @@ struct cmd_element no_debug_ospf6_lsa_type_detail_cmd; void install_element_ospf6_debug_lsa () { - int i; + u_int i; struct ospf6_lsa_handler *handler; #define STRSIZE 256 #define DOCSIZE 1024 @@ -969,7 +970,7 @@ install_element_ospf6_debug_lsa () int config_write_ospf6_debug_lsa (struct vty *vty) { - int i; + u_int i; struct ospf6_lsa_handler *handler; for (i = 0; i < vector_max (ospf6_lsa_handler_vector); i++) |