summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPavel Machek <pavel@ucw.cz>2000-05-19 16:57:40 +0000
committerPavel Machek <pavel@ucw.cz>2000-05-19 16:57:40 +0000
commite66e6c2119e9de2f8012e587eafe752723706265 (patch)
tree811b5fe8ab21eaaccd74c87e518cbb6a60c1e6d2
parent9511a483b1b735d8bf9f671d494b363da5719ecc (diff)
If community list is not defined, act as it is empty.
-rw-r--r--filter/filter.c17
1 files changed, 13 insertions, 4 deletions
diff --git a/filter/filter.c b/filter/filter.c
index dd370088..f6d1b3fc 100644
--- a/filter/filter.c
+++ b/filter/filter.c
@@ -396,20 +396,29 @@ interpret(struct f_inst *what)
if ((!e) && (f_flags & FF_FORCE_TMPATTR))
e = ea_find( (*f_rte)->attrs->eattrs, what->a2.i );
- if (!e) {
- res.type = T_VOID;
- break;
- }
switch (what->aux & EAF_TYPE_MASK) {
case EAF_TYPE_INT:
+ if (!e) {
+ res.type = T_VOID;
+ break;
+ }
res.type = T_INT;
res.val.i = e->u.data;
break;
case EAF_TYPE_AS_PATH:
+ if (!e) {
+ res.type = T_VOID;
+ break;
+ }
res.type = T_PATH;
res.val.ad = e->u.ptr;
break;
case EAF_TYPE_INT_SET:
+ if (!e) {
+ res.type = T_CLIST;
+ res.val.ad = adata_empty(f_pool);
+ break;
+ }
res.type = T_CLIST;
res.val.ad = e->u.ptr;
break;