mirror of
https://github.com/FRRouting/frr.git
synced 2025-04-30 13:37:17 +02:00
lib: Start from 1, not 0 when creating Lua tables for nexthops
Lua technically enumerates arrays from 1, not 0. Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
This commit is contained in:
parent
3d2c589766
commit
b1012b693f
|
@ -323,7 +323,7 @@ void lua_pushnexthop_group(lua_State *L, const struct nexthop_group *ng)
|
|||
{
|
||||
lua_newtable(L);
|
||||
struct nexthop *nexthop;
|
||||
int i = 0;
|
||||
int i = 1;
|
||||
|
||||
for (ALL_NEXTHOPS_PTR(ng, nexthop)) {
|
||||
lua_pushnexthop(L, nexthop);
|
||||
|
|
Loading…
Reference in a new issue