summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJafar Al-Gharaibeh <jafar@atcorp.com>2025-03-14 09:57:41 -0500
committerGitHub <noreply@github.com>2025-03-14 09:57:41 -0500
commit7945af02000541ea6c1dc1ee0321cb5380768baf (patch)
tree4dc98327e199c00113f2dd68ea5cde34d439c0bc
parentdbecefb6c6eac3ad9d798e66ae2a8c572590c0bd (diff)
parent5a63cf4c0d1e7b84f59003877599c6575ba08a25 (diff)
Merge pull request #18360 from raja-rajasekar/rajasekarr/fix_explicit_sid_allocation
zebra: ensure proper return for failure for Sid allocation
-rw-r--r--zebra/zebra_srv6.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/zebra/zebra_srv6.c b/zebra/zebra_srv6.c
index 51efcceb75..f9b5dd8808 100644
--- a/zebra/zebra_srv6.c
+++ b/zebra/zebra_srv6.c
@@ -1236,7 +1236,7 @@ static bool alloc_srv6_sid_func_explicit(struct zebra_srv6_sid_block *block,
zlog_warn("%s: function %u is outside ELIB [%u/%u] and EWLIB alloc ranges [%u/%u]",
__func__, sid_func, elib_start,
elib_end, ewlib_start, ewlib_end);
- return -1;
+ return false;
}
} else if (format->type == SRV6_SID_FORMAT_TYPE_UNCOMPRESSED) {
uint32_t explicit_start =
@@ -1395,7 +1395,7 @@ static bool alloc_srv6_sid_func_dynamic(struct zebra_srv6_sid_block *block,
dynamic_end) {
zlog_warn("%s: SRv6: Warning, SRv6 SID Dynamic alloc space is depleted",
__func__);
- return NULL;
+ return false;
}
/*