Fixes error handling in ASN expressions.
This commit is contained in:
parent
112d71a73f
commit
938b191b92
1 changed files with 1 additions and 4 deletions
|
@ -1150,10 +1150,7 @@ f_eval_asn(struct f_inst *expr)
|
||||||
{
|
{
|
||||||
/* Called as a part of another interpret call, therefore no log_reset() */
|
/* Called as a part of another interpret call, therefore no log_reset() */
|
||||||
struct f_val res = interpret(expr);
|
struct f_val res = interpret(expr);
|
||||||
if (res.type != T_INT)
|
return (res.type == T_INT) ? res.val.i : 0;
|
||||||
cf_error("Can't operate with value of non-integer type in AS path mask constructor");
|
|
||||||
|
|
||||||
return res.val.i;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in a new issue