summaryrefslogtreecommitdiff
path: root/proto
diff options
context:
space:
mode:
authorOndrej Zajicek <santiago@crfreenet.org>2014-03-31 00:56:44 +0200
committerOndrej Zajicek <santiago@crfreenet.org>2014-03-31 01:52:28 +0200
commitd7c0628591b802e202903b63fce53b6a422a3db2 (patch)
tree2202050e07a73c435785565b6e74e0116f8fad39 /proto
parent0c3d9dacafdb807d2101c67610969707353f434a (diff)
Check validity of interface definitions.
Thanks to Aleksey Berezin for the bugreport.
Diffstat (limited to 'proto')
-rw-r--r--proto/bfd/config.Y2
-rw-r--r--proto/ospf/config.Y6
-rw-r--r--proto/radv/config.Y2
-rw-r--r--proto/rip/config.Y2
4 files changed, 8 insertions, 4 deletions
diff --git a/proto/bfd/config.Y b/proto/bfd/config.Y
index 1bf8764f..67a4983b 100644
--- a/proto/bfd/config.Y
+++ b/proto/bfd/config.Y
@@ -89,7 +89,7 @@ bfd_iface_opt_list:
| '{' bfd_iface_opts '}'
;
-bfd_iface: bfd_iface_start iface_patt_list bfd_iface_opt_list
+bfd_iface: bfd_iface_start iface_patt_list_nopx bfd_iface_opt_list
{ add_tail(&BFD_CFG->patt_list, NODE this_ipatt); };
bfd_multihop: bfd_iface_start bfd_iface_opt_list
diff --git a/proto/ospf/config.Y b/proto/ospf/config.Y
index f894f134..90f289d0 100644
--- a/proto/ospf/config.Y
+++ b/proto/ospf/config.Y
@@ -386,6 +386,10 @@ ospf_instance_id:
| INSTANCE expr { set_instance_id($2); }
;
+ospf_iface_patt_list:
+ iface_patt_list { if (OSPF_VERSION == 3) iface_patt_check(); } ospf_instance_id
+ ;
+
ospf_iface_opts:
/* empty */
| ospf_iface_opts ospf_iface_item ';'
@@ -397,7 +401,7 @@ ospf_iface_opt_list:
;
ospf_iface:
- ospf_iface_start iface_patt_list ospf_instance_id ospf_iface_opt_list { ospf_iface_finish(); }
+ ospf_iface_start ospf_iface_patt_list ospf_iface_opt_list { ospf_iface_finish(); }
;
opttext:
diff --git a/proto/radv/config.Y b/proto/radv/config.Y
index ff70a2f7..88a9e298 100644
--- a/proto/radv/config.Y
+++ b/proto/radv/config.Y
@@ -138,7 +138,7 @@ radv_iface_opt_list:
;
radv_iface:
- radv_iface_start iface_patt_list radv_iface_opt_list radv_iface_finish;
+ radv_iface_start iface_patt_list_nopx radv_iface_opt_list radv_iface_finish;
radv_prefix_start: prefix
diff --git a/proto/rip/config.Y b/proto/rip/config.Y
index 791c43a2..76397520 100644
--- a/proto/rip/config.Y
+++ b/proto/rip/config.Y
@@ -110,7 +110,7 @@ rip_iface_init:
}
;
-rip_iface:
+rip_iface: /* TODO: switch to iface_patt_list_nopx */
rip_iface_init iface_patt_list rip_iface_opt_list
;