0
0
mirror of https://gitlab.nic.cz/labs/bird.git synced 2024-12-22 01:31:55 +00:00

Fixes error handling in ASN expressions.

This commit is contained in:
Ondrej Zajicek 2010-10-09 01:00:53 +02:00
parent 112d71a73f
commit 938b191b92

View File

@ -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;
}
/**