This is allowing for recursive table NAME declarations such as:
... table xyz1 table xyz2 { ... }
remove it.
Fixes: 3ed5e31f4a32 ("src: add flow statement")
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
}
;
-meter_stmt : flow_stmt_legacy_alloc flow_stmt_opts '{' meter_key_expr stmt '}'
+meter_stmt : flow_stmt_legacy_alloc TABLE identifier '{' meter_key_expr stmt '}'
{
- $1->meter.key = $4;
- $1->meter.stmt = $5;
+ $1->meter.name = $3;
+ $1->meter.key = $5;
+ $1->meter.stmt = $6;
$$->location = @$;
$$ = $1;
}
}
;
-flow_stmt_opts : flow_stmt_opt
- {
- $<stmt>$ = $<stmt>0;
- }
- | flow_stmt_opts flow_stmt_opt
- ;
-
-flow_stmt_opt : TABLE identifier
- {
- $<stmt>0->meter.name = $2;
- }
- ;
-
meter_stmt_alloc : METER identifier '{' meter_key_expr stmt '}'
{
$$ = meter_stmt_alloc(&@$);