From: Ondrej Zajicek Date: Fri, 8 Oct 2010 23:00:53 +0000 (+0200) Subject: Fixes error handling in ASN expressions. X-Git-Tag: v1.3.0~43 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=938b191b9282b138cbdd30dfc11b78c0467d6380;p=thirdparty%2Fbird.git Fixes error handling in ASN expressions. --- diff --git a/filter/filter.c b/filter/filter.c index 3b150a740..8426a214d 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; } /**