summaryrefslogtreecommitdiff
path: root/bgpd/bgp_clist.c
diff options
context:
space:
mode:
Diffstat (limited to 'bgpd/bgp_clist.c')
-rw-r--r--bgpd/bgp_clist.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/bgpd/bgp_clist.c b/bgpd/bgp_clist.c
index 1fb55ddf7d..d6ac88c09b 100644
--- a/bgpd/bgp_clist.c
+++ b/bgpd/bgp_clist.c
@@ -33,6 +33,7 @@
#include "bgpd/bgp_community.h"
#include "bgpd/bgp_ecommunity.h"
#include "bgpd/bgp_lcommunity.h"
+#include "bgpd/bgp_community_alias.h"
#include "bgpd/bgp_aspath.h"
#include "bgpd/bgp_regex.h"
#include "bgpd/bgp_clist.h"
@@ -557,7 +558,7 @@ static bool community_regexp_match(struct community *com, regex_t *reg)
str = community_str(com, false);
/* Regular expression match. */
- if (regexec(reg, str, 0, NULL, 0) == 0)
+ if (regexec(reg, bgp_alias2community_str(str), 0, NULL, 0) == 0)
return true;
/* No match. */
@@ -627,7 +628,7 @@ static bool lcommunity_regexp_match(struct lcommunity *com, regex_t *reg)
str = lcommunity_str(com, false);
/* Regular expression match. */
- if (regexec(reg, str, 0, NULL, 0) == 0)
+ if (regexec(reg, bgp_alias2community_str(str), 0, NULL, 0) == 0)
return true;
/* No match. */