diff options
Diffstat (limited to 'proto/ospf/lsalib.c')
-rw-r--r-- | proto/ospf/lsalib.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/proto/ospf/lsalib.c b/proto/ospf/lsalib.c index e3df74c..e0871c8 100644 --- a/proto/ospf/lsalib.c +++ b/proto/ospf/lsalib.c @@ -44,12 +44,13 @@ ospf_age(struct ospf_area *oa) struct proto_ospf *po = (struct proto_ospf *) p; struct top_hash_entry *en, *nxt; int flush = can_flush_lsa(oa); + int cleanup = (oa->rt && (oa->rt->dist != LSINFINITY)); OSPF_TRACE(D_EVENTS, "Running ospf_age"); WALK_SLIST_DELSAFE(en, nxt, oa->lsal) { - if (oa->rt && (oa->rt->dist != LSINFINITY)) + if (cleanup) { en->color = OUTSPF; en->dist = LSINFINITY; |