summaryrefslogtreecommitdiffstats
path: root/zebra/zebra_srv6.c
diff options
context:
space:
mode:
authorMark Stapp <mjs@voltanet.io>2021-06-07 20:26:25 +0200
committerMark Stapp <mjs@voltanet.io>2021-06-07 20:26:25 +0200
commitf502d7af0f1d57d855cc67b3bb349226151c4b97 (patch)
tree8770ee8311200c1a8906e9450f5df7f5cc88a47d /zebra/zebra_srv6.c
parentzebra: small srv6 text cleanup (diff)
downloadfrr-f502d7af0f1d57d855cc67b3bb349226151c4b97.tar.xz
frr-f502d7af0f1d57d855cc67b3bb349226151c4b97.zip
zebra: srv6 cleanup
Use NO_PROTO consistently in tests; make sure zapi client instance and session are used for srv6 'chunks'. Signed-off-by: Mark Stapp <mjs@voltanet.io>
Diffstat (limited to 'zebra/zebra_srv6.c')
-rw-r--r--zebra/zebra_srv6.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/zebra/zebra_srv6.c b/zebra/zebra_srv6.c
index 5664a2968..b11331a18 100644
--- a/zebra/zebra_srv6.c
+++ b/zebra/zebra_srv6.c
@@ -181,13 +181,13 @@ assign_srv6_locator_chunk(uint8_t proto,
loc->status_up = false;
chunk = srv6_locator_chunk_alloc();
- chunk->proto = 0;
+ chunk->proto = NO_PROTO;
listnode_add(loc->chunks, chunk);
zebra_srv6_locator_add(loc);
}
for (ALL_LIST_ELEMENTS_RO((struct list *)loc->chunks, node, chunk)) {
- if (chunk->proto != 0 && chunk->proto != proto)
+ if (chunk->proto != NO_PROTO && chunk->proto != proto)
continue;
chunk_found = true;
break;
@@ -199,6 +199,8 @@ assign_srv6_locator_chunk(uint8_t proto,
}
chunk->proto = proto;
+ chunk->instance = instance;
+ chunk->session_id = session_id;
return loc;
}