From 2b1b825268f0f87f60b2a2c4fba372d3c70a2660 Mon Sep 17 00:00:00 2001 From: Kim Hagen Date: Thu, 1 Sep 2016 14:35:17 +0200 Subject: T70: Prefix lists, allow le==ge --- templates/policy/prefix-list/node.tag/rule/node.def | 2 +- templates/policy/prefix-list6/node.tag/rule/node.def | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'templates/policy') diff --git a/templates/policy/prefix-list/node.tag/rule/node.def b/templates/policy/prefix-list/node.tag/rule/node.def index e779122a..9adf6dbe 100644 --- a/templates/policy/prefix-list/node.tag/rule/node.def +++ b/templates/policy/prefix-list/node.tag/rule/node.def @@ -28,7 +28,7 @@ end: len=`echo $VAR(./prefix/@) | awk -F/ '{ print $2 }'` ; cond="ge $VAR(./ge/@) "; fi; if [ -n "$VAR(./le/@)" ]; then - if [ $VAR(./le/@) -ne 32 ] && [ -n "$VAR(./ge/@)" ] && [ $VAR(./le/@) -le $VAR(./ge/@) ]; then + if ! ([ $VAR(./le/@) -ne 32 ] && [ -n "$VAR(./ge/@)" ] && [ $VAR(./le/@) -le $VAR(./ge/@) ]); then echo "le must be greater than or equal to ge"; exit 1 ; fi ; diff --git a/templates/policy/prefix-list6/node.tag/rule/node.def b/templates/policy/prefix-list6/node.tag/rule/node.def index d3540e09..1d0f2acc 100644 --- a/templates/policy/prefix-list6/node.tag/rule/node.def +++ b/templates/policy/prefix-list6/node.tag/rule/node.def @@ -28,7 +28,7 @@ end: len=`echo $VAR(./prefix/@) | awk -F/ '{ print $2 }'` ; cond="ge $VAR(./ge/@) "; fi; if [ -n "$VAR(./le/@)" ]; then - if [ $VAR(./le/@) -ne 128 ] && [ -n "$VAR(./ge/@)" ] && [ $VAR(./le/@) -le $VAR(./ge/@) ]; then + if ! ([ $VAR(./le/@) -ne 128 ] && [ -n "$VAR(./ge/@)" ] && [ $VAR(./le/@) -le $VAR(./ge/@) ]); then echo "le must be greater than or equal to ge"; exit 1 ; fi ; -- cgit v1.2.3