spftree->lastrun = time (NULL);
spftree->pending = 0;
- if (level == 1)
+ if (level == 1) {
+ /* FIXME: Should do it earlier. */
+ spftree->t_spf_periodic = NULL;
THREAD_TIMER_ON(master, spftree->t_spf_periodic, isis_run_spf_l1, area,
isis_jitter(PERIODIC_SPF_INTERVAL, 10));
- else
+ }
+ else {
+ /* FIXME: Should do it earlier. */
+ spftree->t_spf_periodic = NULL;
THREAD_TIMER_ON(master, spftree->t_spf_periodic, isis_run_spf_l2, area,
isis_jitter(PERIODIC_SPF_INTERVAL, 10));
+ }
return retval;
}
}
/* FIXME: This stuff is just mess. All spf thread add/cancel
logic should be reviewed. */
- /* THREAD_TIMER_OFF(spftree->t_spf_periodic); */
+ THREAD_TIMER_OFF(spftree->t_spf_periodic);
if (diff < MINIMUM_SPF_INTERVAL) {
if (level == 1)