Better dumping in neighbor chstate.
This commit is contained in:
parent
8914e37dc0
commit
dd100e40c6
1 changed files with 5 additions and 2 deletions
|
@ -8,6 +8,9 @@
|
||||||
|
|
||||||
#include "ospf.h"
|
#include "ospf.h"
|
||||||
|
|
||||||
|
char *ospf_ns[]={"down", "attempt", "init", "2way", "exstart", "exchange",
|
||||||
|
"loading", "full"};
|
||||||
|
|
||||||
void
|
void
|
||||||
neigh_chstate(struct ospf_neighbor *n, u8 state)
|
neigh_chstate(struct ospf_neighbor *n, u8 state)
|
||||||
{
|
{
|
||||||
|
@ -19,8 +22,8 @@ neigh_chstate(struct ospf_neighbor *n, u8 state)
|
||||||
ifa=n->ifa;
|
ifa=n->ifa;
|
||||||
p=(struct proto *)(ifa->proto);
|
p=(struct proto *)(ifa->proto);
|
||||||
|
|
||||||
debug("%s: Neigbor '%u' changes state from %u to %u.\n", p->name, n->rid,
|
debug("%s: Neigbor '%u' changes state from \"%u\" to \"%u\".\n",
|
||||||
n->state, state);
|
p->name, n->rid, ospf_ns[n->state], ospf_ns[state]);
|
||||||
n->state=state;
|
n->state=state;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue