From 938b191b9282b138cbdd30dfc11b78c0467d6380 Mon Sep 17 00:00:00 2001 From: Ondrej Zajicek Date: Sat, 9 Oct 2010 01:00:53 +0200 Subject: Fixes error handling in ASN expressions. --- filter/filter.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/filter/filter.c b/filter/filter.c index 3b150a7..8426a21 100644 --- a/filter/filter.c +++ b/filter/filter.c @@ -1150,10 +1150,7 @@ f_eval_asn(struct f_inst *expr) { /* Called as a part of another interpret call, therefore no log_reset() */ struct f_val res = interpret(expr); - if (res.type != T_INT) - cf_error("Can't operate with value of non-integer type in AS path mask constructor"); - - return res.val.i; + return (res.type == T_INT) ? res.val.i : 0; } /** -- cgit v1.2.3