summaryrefslogtreecommitdiff
path: root/conf/confbase.Y
diff options
context:
space:
mode:
authorMaria Matejka <mq@ucw.cz>2022-07-10 14:19:24 +0200
committerMaria Matejka <mq@ucw.cz>2022-07-10 14:19:24 +0200
commit7e9cede1fd1878fb4c00e793bccd0ca6c18ad452 (patch)
treea61f837bcbda9aac2c6278d6f3e256e17b41aac3 /conf/confbase.Y
parent652be92a21f5575e5f74f6abe98eb4200b86776c (diff)
parentb867c798c3e42c875311a79fe53a36d4a5bfd126 (diff)
Merge version 2.0.10 into backport
Diffstat (limited to 'conf/confbase.Y')
-rw-r--r--conf/confbase.Y11
1 files changed, 10 insertions, 1 deletions
diff --git a/conf/confbase.Y b/conf/confbase.Y
index 6985783b..5f45c507 100644
--- a/conf/confbase.Y
+++ b/conf/confbase.Y
@@ -110,7 +110,7 @@ CF_DECLS
%type <i> expr bool pxlen4
%type <time> expr_us time
%type <a> ipa
-%type <net> net_ip4_ net_ip6_ net_ip6 net_ip_ net_ip net_or_ipa
+%type <net> net_ip4_ net_ip4 net_ip6_ net_ip6 net_ip_ net_ip net_or_ipa
%type <net_ptr> net_ net_any net_vpn4_ net_vpn6_ net_vpn_ net_roa4_ net_roa6_ net_roa_ net_ip6_sadr_ net_mpls_
%type <mls> label_stack_start label_stack
@@ -303,6 +303,15 @@ net_:
/* Networks - regular */
+net_ip4:
+ net_ip4_
+ | CF_SYM_KNOWN {
+ if (($1->class != (SYM_CONSTANT | T_NET)) || (SYM_VAL($1).net->type != NET_IP4))
+ cf_error("IPv4 network constant expected");
+ $$ = * SYM_VAL($1).net;
+ }
+ ;
+
net_ip6:
net_ip6_
| CF_SYM_KNOWN {