diff options
Diffstat (limited to 'bgpd/bgp_script.c')
| -rw-r--r-- | bgpd/bgp_script.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/bgpd/bgp_script.c b/bgpd/bgp_script.c index f4ab233524..b37385812e 100644 --- a/bgpd/bgp_script.c +++ b/bgpd/bgp_script.c @@ -26,15 +26,16 @@ void lua_pushpeer(lua_State *L, const struct peer *peer) lua_setfield(L, -2, "remote_id"); lua_pushinaddr(L, &peer->local_id); lua_setfield(L, -2, "local_id"); - lua_pushstring(L, lookup_msg(bgp_status_msg, peer->status, NULL)); + lua_pushstring(L, lookup_msg(bgp_status_msg, peer->connection->status, + NULL)); lua_setfield(L, -2, "state"); lua_pushstring(L, peer->desc ? peer->desc : ""); lua_setfield(L, -2, "description"); - lua_pushtimet(L, &peer->uptime); + lua_pushinteger(L, peer->uptime); lua_setfield(L, -2, "uptime"); - lua_pushtimet(L, &peer->readtime); + lua_pushinteger(L, peer->readtime); lua_setfield(L, -2, "last_readtime"); - lua_pushtimet(L, &peer->resettime); + lua_pushinteger(L, peer->resettime); lua_setfield(L, -2, "last_resettime"); lua_pushsockunion(L, peer->su_local); lua_setfield(L, -2, "local_address"); |
