From 1bfee9368adcd91337b4b4b5ad22330678ed0e78 Mon Sep 17 00:00:00 2001 From: Igor Ryzhov Date: Tue, 5 Oct 2021 17:38:21 +0300 Subject: isisd: fix redistribute CLI Currently, it is possible to configure IPv6 protocols for IPv4 redistribution and vice versa in CLI. The YANG model doesn't allow this so the user receives the following error: ``` nfware(config-router)# redistribute ipv4 ospf6 level-1 % Failed to edit configuration. YANG error(s): Invalid enumeration value "ospf6". Invalid enumeration value "ospf6". Invalid enumeration value "ospf6". YANG path: Schema location /frr-isisd:isis/instance/redistribute/ipv4/protocol. ``` Let's make CLI more user-friendly and allow only supported protocols in redistribution commands. Signed-off-by: Igor Ryzhov --- python/clidef.py | 2 ++ 1 file changed, 2 insertions(+) (limited to 'python') diff --git a/python/clidef.py b/python/clidef.py index a47cee2d6b..ba7c9072c5 100644 --- a/python/clidef.py +++ b/python/clidef.py @@ -435,6 +435,8 @@ if __name__ == "__main__": macros.load(os.path.join(basepath, "bgpd/bgp_vty.h")) # sigh :( macros["PROTO_REDIST_STR"] = "FRR_REDIST_STR_ISISD" + macros["PROTO_IP_REDIST_STR"] = "FRR_IP_REDIST_STR_ISISD" + macros["PROTO_IP6_REDIST_STR"] = "FRR_IP6_REDIST_STR_ISISD" errors = process_file(args.cfile, ofd, dumpfd, args.all_defun, macros) if errors != 0: -- cgit v1.2.3