Remove the UNDEFINED_NODE as that it's implementation breaks
our ability in BGP to figure out where we are by allowing
default: in the switch statement.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
case SAFI_ENCAP:
return BGP_ENCAP_NODE;
break;
- default:
- return UNDEFINED_NODE;
- break;
}
break;
case AFI_IP6:
case SAFI_ENCAP:
return BGP_ENCAP_NODE;
break;
- default:
- return UNDEFINED_NODE;
- break;
}
break;
- default:
- return UNDEFINED_NODE;
+ case AFI_L2VPN:
+ return BGP_EVPN_NODE;
+ break;
+ case AFI_MAX:
+ // We should never be here but to clarify the switch statement..
+ return BGP_IPV4_NODE;
break;
}
+
+ // Impossible to happen
+ return BGP_IPV4_NODE;
}
/* Utility function to get address family from current node. */
MPLS_NODE, /* MPLS config node */
VTY_NODE, /* Vty node. */
LINK_PARAMS_NODE, /* Link-parameters node */
- UNDEFINED_NODE
};
/* Node which has some commands and prompt string and configuration