diff options
| -rw-r--r-- | bgpd/bgp_nexthop.c | 6 | ||||
| -rw-r--r-- | bgpd/rfapi/rfapi_rib.c | 5 | ||||
| -rw-r--r-- | isisd/isis_spf.c | 2 | ||||
| -rw-r--r-- | ospf6d/ospf6_top.c | 12 | ||||
| -rw-r--r-- | ospfd/ospf_ldp_sync.c | 2 | ||||
| -rw-r--r-- | ospfd/ospf_vty.c | 8 | ||||
| -rw-r--r-- | pceplib/pcep_msg_tlvs_encoding.c | 3 | ||||
| -rw-r--r-- | ripngd/ripngd.c | 2 | ||||
| -rw-r--r-- | tests/lib/test_srcdest_table.c | 2 | ||||
| -rw-r--r-- | zebra/zebra_nb_state.c | 2 | ||||
| -rw-r--r-- | zebra/zebra_vxlan.c | 4 | 
11 files changed, 21 insertions, 27 deletions
diff --git a/bgpd/bgp_nexthop.c b/bgpd/bgp_nexthop.c index 25174ce654..de48c97513 100644 --- a/bgpd/bgp_nexthop.c +++ b/bgpd/bgp_nexthop.c @@ -396,8 +396,7 @@ void bgp_connected_add(struct bgp *bgp, struct connected *ifc)  		bgp_address_add(bgp, ifc, addr); -		dest = bgp_node_get(bgp->connected_table[AFI_IP], -				    (struct prefix *)&p); +		dest = bgp_node_get(bgp->connected_table[AFI_IP], &p);  		bc = bgp_dest_get_bgp_connected_ref_info(dest);  		if (bc)  			bc->refcnt++; @@ -430,8 +429,7 @@ void bgp_connected_add(struct bgp *bgp, struct connected *ifc)  		bgp_address_add(bgp, ifc, addr); -		dest = bgp_node_get(bgp->connected_table[AFI_IP6], -				    (struct prefix *)&p); +		dest = bgp_node_get(bgp->connected_table[AFI_IP6], &p);  		bc = bgp_dest_get_bgp_connected_ref_info(dest);  		if (bc) diff --git a/bgpd/rfapi/rfapi_rib.c b/bgpd/rfapi/rfapi_rib.c index ba0c576f1e..44eebe961c 100644 --- a/bgpd/rfapi/rfapi_rib.c +++ b/bgpd/rfapi/rfapi_rib.c @@ -2108,10 +2108,9 @@ void rfapiRibPendingDeleteRoute(struct bgp *bgp, struct rfapi_import_table *it,  				sl);  			for (cursor = NULL, -			    rc = skiplist_next(sl, NULL, (void **)&m, -					       (void **)&cursor); +			    rc = skiplist_next(sl, NULL, (void **)&m, &cursor);  			     !rc; rc = skiplist_next(sl, NULL, (void **)&m, -						     (void **)&cursor)) { +						     &cursor)) {  #if DEBUG_PENDING_DELETE_ROUTE  				vnc_zlog_debug_verbose("%s: eth monitor rfd=%p", diff --git a/isisd/isis_spf.c b/isisd/isis_spf.c index 10ba6a35bb..49c62d2cf5 100644 --- a/isisd/isis_spf.c +++ b/isisd/isis_spf.c @@ -706,7 +706,7 @@ static void process_N(struct isis_spftree *spftree, enum vertextype vtype,  	if (vtype >= VTYPE_IPREACH_INTERNAL) {  		memcpy(&p, id, sizeof(p));  		apply_mask(&p.dest); -		apply_mask((struct prefix *)&p.src); +		apply_mask(&p.src);  		id = &p;  	} diff --git a/ospf6d/ospf6_top.c b/ospf6d/ospf6_top.c index 2a6d7cd099..634eabbf70 100644 --- a/ospf6d/ospf6_top.c +++ b/ospf6d/ospf6_top.c @@ -1761,8 +1761,8 @@ bool ospf6_is_valid_summary_addr(struct vty *vty, struct prefix *p)  	memset(&addr_zero, 0, sizeof(struct in6_addr));  	 /* Default prefix validation*/ -	if ((is_default_prefix((struct prefix *)p)) -	   || (!memcmp(&p->u.prefix6, &addr_zero, sizeof(struct in6_addr)))) { +	if ((is_default_prefix(p)) || +	    (!memcmp(&p->u.prefix6, &addr_zero, sizeof(struct in6_addr)))) {  		vty_out(vty, "Default address should not be configured as summary address.\n");  		return false;  	} @@ -1802,7 +1802,7 @@ DEFPY (ospf6_external_route_aggregation,  	}  	/* Apply mask for given prefix. */ -	apply_mask((struct prefix *)&p); +	apply_mask(&p);  	if (!ospf6_is_valid_summary_addr(vty, &p))  		return CMD_WARNING_CONFIG_FAILED; @@ -1850,7 +1850,7 @@ DEFPY(no_ospf6_external_route_aggregation,  	}  	/* Apply mask for given prefix. */ -	apply_mask((struct prefix *)&p); +	apply_mask(&p);  	if (!ospf6_is_valid_summary_addr(vty, &p))  		return CMD_WARNING_CONFIG_FAILED; @@ -1881,7 +1881,7 @@ DEFPY (ospf6_external_route_aggregation_no_advertise,  	}  	/* Apply mask for given prefix. */ -	apply_mask((struct prefix *)&p); +	apply_mask(&p);  	if (!ospf6_is_valid_summary_addr(vty, &p))  		return CMD_WARNING_CONFIG_FAILED; @@ -1913,7 +1913,7 @@ DEFPY (no_ospf6_external_route_aggregation_no_advertise,  	}  	/* Apply mask for given prefix. */ -	apply_mask((struct prefix *)&p); +	apply_mask(&p);  	if (!ospf6_is_valid_summary_addr(vty, &p))  		return CMD_WARNING_CONFIG_FAILED; diff --git a/ospfd/ospf_ldp_sync.c b/ospfd/ospf_ldp_sync.c index b4d770d48a..330a433627 100644 --- a/ospfd/ospf_ldp_sync.c +++ b/ospfd/ospf_ldp_sync.c @@ -326,7 +326,7 @@ void ospf_ldp_sync_if_remove(struct interface *ifp, bool remove)  	if (!CHECK_FLAG(ldp_sync_info->flags, LDP_SYNC_FLAG_IF_CONFIG))  		ldp_sync_info->enabled = LDP_IGP_SYNC_DEFAULT;  	if (remove) { -		ldp_sync_info_free((struct ldp_sync_info **)&(ldp_sync_info)); +		ldp_sync_info_free(&ldp_sync_info);  		params->ldp_sync_info = NULL;  	}  } diff --git a/ospfd/ospf_vty.c b/ospfd/ospf_vty.c index 3bd4a9bb68..20b9180cff 100644 --- a/ospfd/ospf_vty.c +++ b/ospfd/ospf_vty.c @@ -10036,7 +10036,7 @@ DEFUN (ospf_external_route_aggregation,  	}  	/* Apply mask for given prefix. */ -	apply_mask((struct prefix *)&p); +	apply_mask(&p);  	if (!is_valid_summary_addr(&p)) {  		vty_out(vty, "Not a valid summary address.\n"); @@ -10077,7 +10077,7 @@ DEFUN (no_ospf_external_route_aggregation,  	}  	/* Apply mask for given prefix. */ -	apply_mask((struct prefix *)&p); +	apply_mask(&p);  	if (!is_valid_summary_addr(&p)) {  		vty_out(vty, "Not a valid summary address.\n"); @@ -10377,7 +10377,7 @@ DEFUN (ospf_external_route_aggregation_no_adrvertise,  	}  	/* Apply mask for given prefix. */ -	apply_mask((struct prefix *)&p); +	apply_mask(&p);  	if (!is_valid_summary_addr(&p)) {  		vty_out(vty, "Not a valid summary address.\n"); @@ -10413,7 +10413,7 @@ DEFUN (no_ospf_external_route_aggregation_no_adrvertise,  	}  	/* Apply mask for given prefix. */ -	apply_mask((struct prefix *)&p); +	apply_mask(&p);  	if (!is_valid_summary_addr(&p)) {  		vty_out(vty, "Not a valid summary address.\n"); diff --git a/pceplib/pcep_msg_tlvs_encoding.c b/pceplib/pcep_msg_tlvs_encoding.c index c46e859c49..b5a65d457b 100644 --- a/pceplib/pcep_msg_tlvs_encoding.c +++ b/pceplib/pcep_msg_tlvs_encoding.c @@ -1185,8 +1185,7 @@ pcep_decode_tlv_pol_id(struct pcep_object_tlv_header *tlv_hdr,  		return (struct pcep_object_tlv_header *)ipv4;  	} else {  		ipv4->is_ipv4 = false; -		struct pcep_object_tlv_srpag_pol_id *ipv6 = -			(struct pcep_object_tlv_srpag_pol_id *)ipv4; +		struct pcep_object_tlv_srpag_pol_id *ipv6 = ipv4;  		ipv6->color = ntohl(uint32_ptr[0]);  		decode_ipv6(&uint32_ptr[1], &ipv6->end_point.ipv6);  		return (struct pcep_object_tlv_header *)ipv6; diff --git a/ripngd/ripngd.c b/ripngd/ripngd.c index e103cdc3a8..5fc1e34592 100644 --- a/ripngd/ripngd.c +++ b/ripngd/ripngd.c @@ -217,7 +217,7 @@ int ripng_send_packet(caddr_t buf, int bufsize, struct sockaddr_in6 *to,  	msg.msg_namelen = sizeof(struct sockaddr_in6);  	msg.msg_iov = &iov;  	msg.msg_iovlen = 1; -	msg.msg_control = (void *)adata; +	msg.msg_control = adata;  	msg.msg_controllen = CMSG_SPACE(sizeof(struct in6_pktinfo));  	iov.iov_base = buf; diff --git a/tests/lib/test_srcdest_table.c b/tests/lib/test_srcdest_table.c index 3c3129b9ce..2d8f024d16 100644 --- a/tests/lib/test_srcdest_table.c +++ b/tests/lib/test_srcdest_table.c @@ -328,7 +328,7 @@ static void get_rand_prefix(struct prng *prng, struct prefix_ipv6 *p)  	p->prefixlen = prng_rand(prng) % 129;  	p->family = AF_INET6; -	apply_mask((struct prefix *)p); +	apply_mask(p);  }  static void get_rand_prefix_pair(struct prng *prng, struct prefix_ipv6 *dst_p, diff --git a/zebra/zebra_nb_state.c b/zebra/zebra_nb_state.c index a9cb096aee..219e4d028a 100644 --- a/zebra/zebra_nb_state.c +++ b/zebra/zebra_nb_state.c @@ -248,7 +248,7 @@ lib_vrf_zebra_ribs_rib_route_get_next(struct nb_cb_get_next_args *args)  	if (args->list_entry == NULL)  		rn = route_top(zrt->table);  	else -		rn = srcdest_route_next((struct route_node *)rn); +		rn = srcdest_route_next(rn);  	/* Optimization: skip empty route nodes. */  	while (rn && rn->info == NULL)  		rn = route_next(rn); diff --git a/zebra/zebra_vxlan.c b/zebra/zebra_vxlan.c index d883336f00..020ff6f3c0 100644 --- a/zebra/zebra_vxlan.c +++ b/zebra/zebra_vxlan.c @@ -1078,9 +1078,7 @@ static int zevpn_build_hash_table_zns(struct ns *ns,  static void zevpn_build_hash_table(void)  { -	ns_walk_func(zevpn_build_hash_table_zns, -		     (void *)NULL, -		     (void **)NULL); +	ns_walk_func(zevpn_build_hash_table_zns, NULL, NULL);  }  /*  | 
