install_element(CONFIG_NODE, &no_debug_ospf6_abr_cmd);
}
-static const struct ospf6_lsa_handler inter_prefix_handler = {
+static struct ospf6_lsa_handler inter_prefix_handler = {
.lh_type = OSPF6_LSTYPE_INTER_PREFIX,
.lh_name = "Inter-Prefix",
.lh_short_name = "IAP",
.lh_get_prefix_str = ospf6_inter_area_prefix_lsa_get_prefix_str,
.lh_debug = 0};
-static const struct ospf6_lsa_handler inter_router_handler = {
+static struct ospf6_lsa_handler inter_router_handler = {
.lh_type = OSPF6_LSTYPE_INTER_ROUTER,
.lh_name = "Inter-Router",
.lh_short_name = "IAR",
return CMD_SUCCESS;
}
-static const struct ospf6_lsa_handler as_external_handler = {
+static struct ospf6_lsa_handler as_external_handler = {
.lh_type = OSPF6_LSTYPE_AS_EXTERNAL,
.lh_name = "AS-External",
.lh_short_name = "ASE",
__func__, oa->name);
}
-static const struct ospf6_lsa_handler router_handler = {
+static struct ospf6_lsa_handler router_handler = {
.lh_type = OSPF6_LSTYPE_ROUTER,
.lh_name = "Router",
.lh_short_name = "Rtr",
.lh_get_prefix_str = ospf6_router_lsa_get_nbr_id,
.lh_debug = 0};
-static const struct ospf6_lsa_handler network_handler = {
+static struct ospf6_lsa_handler network_handler = {
.lh_type = OSPF6_LSTYPE_NETWORK,
.lh_name = "Network",
.lh_short_name = "Net",
.lh_get_prefix_str = ospf6_network_lsa_get_ar_id,
.lh_debug = 0};
-static const struct ospf6_lsa_handler link_handler = {
+static struct ospf6_lsa_handler link_handler = {
.lh_type = OSPF6_LSTYPE_LINK,
.lh_name = "Link",
.lh_short_name = "Lnk",
.lh_get_prefix_str = ospf6_link_lsa_get_prefix_str,
.lh_debug = 0};
-static const struct ospf6_lsa_handler intra_prefix_handler = {
+static struct ospf6_lsa_handler intra_prefix_handler = {
.lh_type = OSPF6_LSTYPE_INTRA_PREFIX,
.lh_name = "Intra-Prefix",
.lh_short_name = "INP",
.lh_debug = 0 /* No default debug */
};
-void ospf6_install_lsa_handler(const struct ospf6_lsa_handler *handler)
+void ospf6_install_lsa_handler(struct ospf6_lsa_handler *handler)
{
/* type in handler is host byte order */
int index = handler->lh_type & OSPF6_LSTYPE_FCODE_MASK;
vector_set_index(ospf6_lsa_handler_vector, index, (void *)handler);
}
-const struct ospf6_lsa_handler *ospf6_get_lsa_handler(uint16_t type)
+struct ospf6_lsa_handler *ospf6_get_lsa_handler(uint16_t type)
{
- const struct ospf6_lsa_handler *handler = NULL;
+ struct ospf6_lsa_handler *handler = NULL;
unsigned int index = ntohs(type) & OSPF6_LSTYPE_FCODE_MASK;
if (index >= vector_active(ospf6_lsa_handler_vector))
extern int ospf6_lsa_prohibited_duration(uint16_t type, uint32_t id,
uint32_t adv_router, void *scope);
-extern void ospf6_install_lsa_handler(const struct ospf6_lsa_handler *handler);
-extern const struct ospf6_lsa_handler *ospf6_get_lsa_handler(uint16_t type);
+extern void ospf6_install_lsa_handler(struct ospf6_lsa_handler *handler);
+extern struct ospf6_lsa_handler *ospf6_get_lsa_handler(uint16_t type);
extern void ospf6_lsa_init(void);
extern void ospf6_lsa_terminate(void);