bgpd: Use route_map_result_t for route_map_apply() as return type

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
This commit is contained in:
Donatas Abraitis 2022-09-20 10:45:02 +03:00
parent c4d75d0275
commit fd283bd250
2 changed files with 16 additions and 1 deletions

View File

@ -983,7 +983,7 @@ struct attr *bgp_attr_aggregate_intern(
{
struct attr attr;
struct attr *new;
int ret;
route_map_result_t ret;
memset(&attr, 0, sizeof(attr));

View File

@ -0,0 +1,15 @@
@rmap@
identifier ret;
position p;
@@
int ret@p;
...
* ret = route_map_apply(...);
@script:python@
p << rmap.p;
@@
msg = "ERROR: Invalid type of return value variable for route_map_apply_ext()"
coccilib.report.print_report(p[0], msg)