summaryrefslogtreecommitdiff
path: root/proto/static
diff options
context:
space:
mode:
authorMaria Matejka <mq@ucw.cz>2022-05-31 12:51:34 +0200
committerMaria Matejka <mq@ucw.cz>2022-05-31 12:51:34 +0200
commitea109ce3e3474dd10d7592c44d2371b794f5c867 (patch)
treebfd5e54e1fa8f50efd5456a54dc1ebf508c1804c /proto/static
parent1493695c6ba2b169523f7c2097fac8e8343352fe (diff)
parent4fe9881d625f10e44109a649e369a413bd98de71 (diff)
Merge commit '4fe9881d625f10e44109a649e369a413bd98de71' into haugesund
Diffstat (limited to 'proto/static')
-rw-r--r--proto/static/static.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/proto/static/static.c b/proto/static/static.c
index 8e389390..038ee018 100644
--- a/proto/static/static.c
+++ b/proto/static/static.c
@@ -100,11 +100,11 @@ static_announce_rte(struct static_proto *p, struct static_route *r)
if (r->dest == RTDX_RECURSIVE)
{
rtable *tab = ipa_is_ip4(r->via) ? p->igp_table_ip4 : p->igp_table_ip6;
- if (r->mls)
- ea_set_attr(&a->eattrs,
- EA_LITERAL_DIRECT_ADATA(&ea_mpls_labels, 0, r->mls));
+ u32 *labels = r->mls ? (void *) r->mls->data : NULL;
+ u32 lnum = r->mls ? r->mls->length / sizeof(u32) : 0;
- rta_set_recursive_next_hop(p->p.main_channel->table, a, tab, r->via, IPA_NONE);
+ ea_set_hostentry(&a->eattrs, p->p.main_channel->table, tab,
+ r->via, IPA_NONE, lnum, labels);
}
/* Already announced */