mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-06 07:37:54 +00:00
bgpd: print error when as-path filter doesn't exist
Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
This commit is contained in:
parent
6431621e4e
commit
17b4e8c439
@ -507,14 +507,16 @@ DEFUN(no_as_path, no_bgp_as_path_cmd,
|
||||
/* Lookup asfilter. */
|
||||
asfilter = as_filter_lookup(aslist, regstr, type);
|
||||
|
||||
XFREE(MTYPE_TMP, regstr);
|
||||
bgp_regex_free(regex);
|
||||
|
||||
if (asfilter == NULL) {
|
||||
vty_out(vty, "\n");
|
||||
vty_out(vty, "Regex entered %s does not exist\n", regstr);
|
||||
XFREE(MTYPE_TMP, regstr);
|
||||
return CMD_WARNING_CONFIG_FAILED;
|
||||
}
|
||||
|
||||
XFREE(MTYPE_TMP, regstr);
|
||||
|
||||
as_list_filter_delete(aslist, asfilter);
|
||||
|
||||
return CMD_SUCCESS;
|
||||
|
Loading…
Reference in New Issue
Block a user