*/
static int process_type5_route(struct peer *peer, afi_t afi, safi_t safi,
struct attr *attr, uint8_t *pfx, int psize,
- uint32_t addpath_id, int withdraw)
+ uint32_t addpath_id)
{
struct prefix_rd prd;
struct prefix_evpn p;
*/
/* Process the route. */
- if (!withdraw)
+ if (attr)
ret = bgp_update(peer, (struct prefix *)&p, addpath_id, attr,
afi, safi, ZEBRA_ROUTE_BGP, BGP_ROUTE_NORMAL,
&prd, &label, 1, 0, &evpn);
break;
case BGP_EVPN_IP_PREFIX_ROUTE:
- if (process_type5_route(peer, afi, safi, attr, pnt,
- psize, addpath_id, withdraw)) {
+ if (process_type5_route(peer, afi, safi,
+ withdraw ? NULL : attr, pnt,
+ psize, addpath_id)) {
flog_err(
EC_BGP_PKT_PROCESS,
"%u:%s - Error in processing EVPN type-5 NLRI size %d",