mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-05-01 14:40:24 +00:00
babeld: be more explicit about route resize result
Resizing the route array can fail. Although the error condition is already correctly handled, if we're more explicit about the variables we expect to be initialized then clang-analyze is happier. Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
This commit is contained in:
parent
316f27e169
commit
aaf24c74e4
@ -176,6 +176,7 @@ insert_route(struct babel_route *route)
|
||||
resize_route_table(max_route_slots < 1 ? 8 : 2 * max_route_slots);
|
||||
if(route_slots >= max_route_slots)
|
||||
return NULL;
|
||||
assert(routes);
|
||||
route->next = NULL;
|
||||
if(n < route_slots)
|
||||
memmove(routes + n + 1, routes + n,
|
||||
|
Loading…
Reference in New Issue
Block a user