]> git.puffer.fish Git - matthieu/frr.git/commit
lib: fix prefix-list duplication check
authorIgor Ryzhov <iryzhov@nfware.com>
Tue, 10 Aug 2021 18:46:37 +0000 (21:46 +0300)
committermergify-bot <noreply@mergify.io>
Tue, 17 Aug 2021 14:01:29 +0000 (14:01 +0000)
commit7923133ff6c5c9179400c16894284d4d778db341
tree1fd44e3f1409b5d232f25e7f258fa7fd4bfcf4e6
parent46cc2c7dc09c165269fe8b3ceb68cb6c1a749f08
lib: fix prefix-list duplication check

Currently, when we check the new prefix-list entry for duplication, we
only take filled in fields into account and ignore optional fields.
For example, if we already have `ip prefix-list A 0.0.0.0/0 le 32` and
we try to add `ip prefix-list A 0.0.0.0/0`, it is treated as duplicate.
We should always compare all prefix-list fields when doing the check.

Fixes #9355.

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
(cherry picked from commit 667dcc277c15c0bddc785f9b949d658f8d815818)
lib/filter.h
lib/filter_cli.c
lib/filter_nb.c